Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 71531

Ionic 4 routing caching / history preservation

$
0
0

@f1v wrote:

Hi,

I have been having an ongoing problem which I haven’t found any clean solutions to, so I decided to repost this with a video demo and github code to better demonstrate how this actually appears to be a problem with routing or caching? Not sure.

To keep it very short, here are the steps:

  1. Login screen, click “Login”
  2. On successful login you see a number of users
  3. Click “Person A”
  4. “Person A” is found in “Case X”
  5. Click “Case X”
  6. Inside “Case X” obviously we see linked “Person A”
  7. Click “Person A” again
  8. Now click “Back” button.

Here is a problem. I expect the back button to take me to Case step #6.

Instead, it takes me all the way back to step #2.

YouTube demo: https://www.youtube.com/watch?v=9RvbZQp8kD8

Github repo: https://github.com/f1vlad/ionic4routing

The cleanest workaround I found was to pass a url param from “Case X” to “Person A”. If param exists, back button would take user from person to case; otherwise, if no location history exists, fall back on default.

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 71531

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>