Web: Clients: Uncommented self.skipWaiting() on install service-worker
This commit is contained in:
parent
bfee8e1365
commit
bc8613c4f6
@ -13,10 +13,10 @@ if ("function" === typeof importScripts) {
|
||||
// to force update an exiting service worker.
|
||||
// Since we're using `injectManifest` to build SW,
|
||||
// manually overriding the skipWaiting();
|
||||
// self.addEventListener("install", event => {
|
||||
// self.skipWaiting();
|
||||
// window.location.reload();
|
||||
// });
|
||||
self.addEventListener("install", event => {
|
||||
self.skipWaiting();
|
||||
window.location.reload();
|
||||
});
|
||||
|
||||
/* injection point for manifest files. */
|
||||
workbox.precaching.precacheAndRoute(self.__WB_MANIFEST);
|
||||
|
@ -13,10 +13,10 @@ if ("function" === typeof importScripts) {
|
||||
// to force update an exiting service worker.
|
||||
// Since we're using `injectManifest` to build SW,
|
||||
// manually overriding the skipWaiting();
|
||||
// self.addEventListener("install", event => {
|
||||
// self.skipWaiting();
|
||||
// window.location.reload();
|
||||
// });
|
||||
self.addEventListener("install", event => {
|
||||
self.skipWaiting();
|
||||
window.location.reload();
|
||||
});
|
||||
|
||||
/* injection point for manifest files. */
|
||||
workbox.precaching.precacheAndRoute(self.__WB_MANIFEST);
|
||||
|
@ -13,10 +13,10 @@ if ("function" === typeof importScripts) {
|
||||
// to force update an exiting service worker.
|
||||
// Since we're using `injectManifest` to build SW,
|
||||
// manually overriding the skipWaiting();
|
||||
// self.addEventListener("install", event => {
|
||||
// self.skipWaiting();
|
||||
// window.location.reload();
|
||||
// });
|
||||
self.addEventListener("install", event => {
|
||||
self.skipWaiting();
|
||||
window.location.reload();
|
||||
});
|
||||
|
||||
/* injection point for manifest files. */
|
||||
workbox.precaching.precacheAndRoute(self.__WB_MANIFEST);
|
||||
|
Loading…
Reference in New Issue
Block a user