ServiceWorker fetch failed (ERR_NAME_NOT_RESOLVED)
See original GitHub issueInstalling serviceworker using following code fails with ERR_NAME_NOT_RESOLVED I am able to load sw.js file using ajax and via script tag just fine
navigator.serviceWorker.register('sw.js').then(function(registration) {
console.log('ServiceWorker registration successful with scope: ', registration.scope);
}, function(err) {
console.log('ServiceWorker registration failed: ', err);
});
The result is
An unknown error occurred when fetching the script.
Failed to load resource: net::ERR_NAME_NOT_RESOLVED
ServiceWorker registration failed: TypeError: Failed to register a ServiceWorker: An unknown error occurred when fetching the script.
Issue Analytics
- State:
- Created 5 years ago
- Comments:6
Top Results From Across the Web
Service Worker Fetch Error When Trying to Load --- My ...
I am not getting a failed fetch in Network Tab but an Error Message in the console. Maybe you can take a look...
Read more >ERR_NAME_NOT_RESOLVED: 6 Proven Methods to Fix It
This article will explain what it is, why this error occurs, and six effective methods to resolve it. Error code, ERR_NAME_NOT_RESOLVED. Error type,...
Read more >Service Workers - When Fetch Goes Wrong - YouTube
This is the seventh video in the Understanding Service Workers course.This video explains how you can use your Service Worker to handle an ......
Read more >ERR_NAME_NOT_RESOLVED: 6 Ways to Fix It
This article features several guides that will help you fix this error. err name not resolved. The ERR_NAME_NOT_RESOLVED Google Chrome error ...
Read more >FetchEvent.respondWith() - Web APIs - MDN Web Docs
This means, for example, if a service worker intercepts a stylesheet or worker script, ... Otherwise, a network error is returned to Fetch....
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
Got it, thanks for confirming. We would want to make sure any web content loads in Carlo, so your SW request stands as a bug report.
Web Push support (GCM) from Service Worker pushManager would be great as electron doesn’t support it: https://github.com/electron/electron/issues/6697