I have created a PWA which is validated by the Google Chrome Lighthouse
audit tool. On Android Phones the native "Add to Homescreen" prompt is displayed and on iOS, a custom "Add to Homescreen" prompt is shown.
The problem is that on iOS the PWA saves the session and I am not redirected to the "start_url".
I need an option to always direct users to the "start_url" if they close the app and reopen it afterward.
Here are the PWA files: https://www.ta-systems.net/BE-Utilities/pwc/test/
I have tried mentioned in the PWA documentation, however, I was not able to get the App to refresh every time it is restarted.
The complete code can be found here: https://www.ta-systems.net/BE-Utilities/pwc/test/
The expected result should be that the application redirects to a different HTML page after 5 seconds & once the app is closed and relaunched the "start_url" should be reopened.
What happens at the moment is the following:
What happened for your PWA is that it saved the session state after you closed it. Starting iOS 12.2, Apple fixed PWA so that it is able to keep PWA session state. However, there is still a problem that Apple needs to fix: it saves the state regardless if you minimize the app (by going to home screen) or close it (by swiping up on app-switch mode). According to this article (https://wespeter.com/posts/ios13-pwa-improvements/) Apple will be fixing in iOS 13 so that it starts your PWA from scratch (start_url) after force quit by swiping up, and only keeps the state when minimize to home screen without force quit and reopen.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With