Борьба с кэшем

This commit is contained in:
FrigaT
2026-04-21 21:43:05 +03:00
parent d2df57ca6e
commit 64cc0e68a1
3 changed files with 14 additions and 4 deletions

View File

@@ -17,8 +17,6 @@ const baseUrl = new URL(base, self.origin);
const manifestUrlList = self.assetsManifest.assets.map(asset => new URL(asset.url, baseUrl).href);
async function onInstall(event) {
console.info('Service worker: Install');
self.skipWaiting();
// Fetch and cache all matching items from the assets manifest
@@ -30,8 +28,6 @@ async function onInstall(event) {
}
async function onActivate(event) {
console.info('Service worker: Activate');
await self.clients.claim();
// Delete unused caches