Change the name of the generated service worker
Opened this issue · 0 comments
anz000 commented
I want to change the name of the generated service worker. The default sw.js
to service-worker.js
, and all the workflow to look for the new service work URL at /service-worker.js
.
On a different note, I had a different app register as service-worker.js
. I plan to have the nuxt app on the same domain. I explored few options, but it didn't work out:
- The default
sw.js
doesn't take over. - I tried using
enabled: false
so that old service worker from previous app would be deleted, but it doesn't. - I manually renamed
sw.js
toservice-worker.js
, which overrides the old one. But all subsequent reloads still search forsw.js
.