From 0120718ee3b7f7437dcb0894906f1db349d4b055 Mon Sep 17 00:00:00 2001 From: GuDzpoz <GuDzpoz@live.com> Date: Wed, 7 Jul 2021 16:18:14 +0800 Subject: [PATCH] Service worker: now skipWaiting. --- sw.js | 1 + 1 file changed, 1 insertion(+) diff --git a/sw.js b/sw.js index 095cb15..9b70919 100644 --- a/sw.js +++ b/sw.js @@ -9,6 +9,7 @@ var cacheContents = [ self.addEventListener("install", function(e) { console.log("[Service Worker] Install"); + self.skipWaiting(); e.waitUntil( caches.open(cacheName).then(function(cache) { console.log("[Service Worker] Caching contents"); -- GitLab