I am having a problem with iOS only, but I think it is also on android but I can’t replicate the behaviour.
the problem consists of:
- I’m on the dashboard which is a tabbed page, a go to page 1.
- page 1 loads async values in “ionViewLoaded” event, but first it calls the present loading.
- present loading gets dismissed, on observable subscribe complete
- I click on one of the results and go to page 2, same thing loading shows and gets dismissed on subscribe complete.
Now the error:
- from page 2 when I click (back) on iOS it, acts like a double back, meaning it goes back to page 1 but hangs the dashboard on the middle of page one.
I can only test on the emulator iOS 9.3 iphone 6, since I dont have an iphone available
I have tried:
- disabling the swipe to back (swipeBackEnabled=“false”) on all the 3 tabs. I tried this because I thought that when I pressed back it was somehow dragging the click to simulate a swipe gesture, making it go back again and freezing.
- I used to have the async data load from page 1 in the ngOnInit event, making it load again everytime it entered the page, switch it to ionViewLoaded so that it only loads on enter to, not when going back to.
None of those work. Another one I’ve tried is setting the “pageTransitionDelay” in the ionicBootstrap config, to 200 milliseconds, (I hate it because it makes the app look slow), and that kinda looks like it wants to work but, the behaviour changes to instead of doing a double back it will do the animation of page 2 leaving (and if you tap a couple of time when the animation is running), it will leave and appear again on top. basically it shows page 2 leaving but then it appears back on top, this only happens if you tap while the animation is happening