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
When using a pwa, you expect the app to work as a mobile app. A mobile app is generally supposed to contain everything it needs to "work" offline (with a degraded service). In fact, you don't want your mobile app to crash all the time when you loose network. Currently, when trying to access offline a lazy loaded component which is not cached, the app crashes
Steps to reproduce
Configure a route with lazy loading
Access your app (and eventually install it as a pwa)
Shut down your network
Access your lazy loaded component
App crashes
Expected behavior
I think this could be improved the following ways
Lazy loaded scripts could actually be prefetched. I know that this is not totally what you expect when you make them lazy loaded. I think the main advantage of lazy loaded comes with the fact that it can split the .js in bundle files. Then, prefetching them is probably a good option. Networks are now fast enough to download completely an app without interference. With prefetching, pwa and offline app works as expected. Only dynamic content is not shown ...
This can be done with this plugin
If the previous approach is not kepts, I think the template should definitely implement an HOC ErrorBoundary component which would display a message to the user in case of any rendering or loading error.
Versions
React-Boilerplate: latest
Node/NPM: latest
Browser: chrome latest
The text was updated successfully, but these errors were encountered:
Description
When using a pwa, you expect the app to work as a mobile app. A mobile app is generally supposed to contain everything it needs to "work" offline (with a degraded service). In fact, you don't want your mobile app to crash all the time when you loose network. Currently, when trying to access offline a lazy loaded component which is not cached, the app crashes
Steps to reproduce
Expected behavior
This can be done with this plugin
Versions
The text was updated successfully, but these errors were encountered: