fix(pwa) fix PWA worker script origin
Looks like the base it's still applied, so use a full URL.
This commit is contained in:
parent
ad265d5815
commit
348c6416e5
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
if (shouldRegisterWorker) {
|
if (shouldRegisterWorker) {
|
||||||
navigator.serviceWorker
|
navigator.serviceWorker
|
||||||
.register('/pwa-worker.js')
|
.register(window.location.origin + '/pwa-worker.js')
|
||||||
.then(reg => {
|
.then(reg => {
|
||||||
console.log('Service worker registered.', reg);
|
console.log('Service worker registered.', reg);
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue