I am testing on the Android Emulator for now. I had a pre-existing mobile webapp that I put into the src/ directory of a fresh Forge workspace. Everything is working pretty well, but…
When the app goes into the background (in this case on account of me pressing the home button, but could also happen as a result of an incoming phone call) and then I return to it, it’s back at index.html, regardless of which page I was on before I went into the background.
Is there a way to have it preserve its state like a real app would?
I have not seen this issue because I use a single .html page app with backbone.js. However, you can possibly try to mitigate this issue by using the event module.
You could “save” the current page in this event:
Then you could “resume” your page using this event: