app crashed after reload/refresh using web workers
See original GitHub issueNWJS Version : 0.46.0-sdk Operating System : OSX
Expected behavior
Don’t crash.
Actual behavior
How to reproduce
- Open app.
- Register web worker.
self.onmessage = e => console.log(e);
self.postMessage('OK');
nw.Window.get().reload()
- Wait 5-20s.
More info
- tested on 0.45.4 - 0.46.0 with same result
nw.Window.get().reloadDev()
=>TypeError: nw.Window.get(...).reloadDev is not a function
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
How to Fix the Refresh Button When Using Service Workers
In a previous article, I explained how and why Service Workers break the browser's Refresh button by default. Getting this right requires an ......
Read more >Service worker issue: page never loads when ...
I now understand that the service worker is replaced when "Update on reload" is checked even if the service worker hasn't changed.
Read more >How To Hard Reload Your React Web App Using Error ...
You just need to write the logic to hard reload the page when the user hits the refresh button. Step 1: Uninstall service...
Read more >The service worker lifecycle - web.dev
If you force-reload the page (shift-reload) it bypasses the service worker entirely. It'll be uncontrolled. This feature is in the spec, so it ......
Read more >Let It Crash: Best Practices for Handling Node.js Errors on ...
At last, we arrive at higher-level error types: the error events thrown by JavaScript itself. When a JavaScript error is not properly handled, ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is fixed in git and will be available in the next nightly build.
This issue also happens on 0.61.0.0 @rogerwang