-
Notifications
You must be signed in to change notification settings - Fork 125
No active Service Worker Error #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
It looks like that the method You can wait for the service worker to become active with the
|
Try changing your vapid keys, as shown in the video (I suggest generate your own pair). |
@ralscha great explanation on the solution. I had also encountered the same problem that @SethuSenthil had. |
@ralscha legend! |
i use your code but when i run , i have a bug 'DOMException: Registration failed - permission denied' |
@dth2k1 Did you block notification for this URL? Chrome: Open Settings, search for "site settings", open Site Settings, scroll down to Permissions, click on Notifications. There you find a list of all URLs you blocked. |
I tried it but did not work for me |
@aditodkar What error do you get? |
In my case register.pushManager.subscribe is never fulfilled I tried to wrap it inside try/catch block but does not throw any error. Same thing happened https://stackoverflow.com/questions/46633866/reg-pushmanager-subscribe-is-never-fulfilled But after clearing cache and making some code changes I was able to resolve it.
|
Hi! I really appreciate your youtube video on how to use push notifications with node. But I'm having an issue on client.js line 6 (where it catches errors, so line # is not that helpful)
Error:
DOMException: Subscription failed - no active Service Worker
I believe the service worker is not registered so it can proceed any further. I also tried downloading the code straight from the repo and I'm still getting this error. Thanks in advance!
The text was updated successfully, but these errors were encountered: