You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The behaviour of next-pwa which causes the page to be reloaded when the browser goes back "online" is not always the desired behaviour. When this happens it causes the app to lose its most recent state and interrupts the Users experience.
Is there a reason why this code exists (i.e. is it solving another problem)? If it was to be removed/disable would it cause other unexpected behaviour or defects?
Could this behaviour be configurable?
Versions
next-pwa: 5.2.21
next: 11.0.0
How To Reproduce
Steps to reproduce the behavior:
Go to a next-pwa app
Switch the network to "offline" in Dev Tools
Switch the network to "online" in Dev Tools
See the page reload
Expected Behaviors
Ideally, we can set a new flag in next.config.js e.g.:
Summary
The behaviour of next-pwa which causes the page to be reloaded when the browser goes back "online" is not always the desired behaviour. When this happens it causes the app to lose its most recent state and interrupts the Users experience.
The code which causes this is here:
next-pwa/register.js
Lines 77 to 79 in e1d3129
Is there a reason why this code exists (i.e. is it solving another problem)? If it was to be removed/disable would it cause other unexpected behaviour or defects?
Could this behaviour be configurable?
Versions
next-pwa
: 5.2.21next
: 11.0.0How To Reproduce
Steps to reproduce the behavior:
Expected Behaviors
Ideally, we can set a new flag in
next.config.js
e.g.:Additional Context
If this sounds reasonable, I'm happy to open a PR 👍
The text was updated successfully, but these errors were encountered: