I have an app in Ionic 5 and angular with deep navigation stack with dozens of pages in stack in normal usage session. So during user expects to see the same ui or view they have left when they load it from recent list.
But when the user idling the phone in app itself or outside of the application, the OS destroys the state of the app and causes it to reinitialise.
Like the above situation I can’t manually manipulate the navigation stack to restore the state of the application in cases where the OS decides to destroy the app state for battery conservation, memory clean etc like procedures, which mainly causes issues in phones having low spec ram configuration.
This causes the app to reinitialise and the user will be seeing the home page instead of the page that user was on, which in user perspective is wrong
as mentioned in the above link I tried to manually save all the pages into storage and retrieve in reinitialising cases.
So how does one manage such cases when using Ionic 5. Is there any builtin methods, or is this some kind of limitation of ionic framework.
PS: If any more info is needed please mention it.