대시보드 문서 캐시 방지
This commit is contained in:
@@ -1,12 +1,5 @@
|
||||
const CACHE_NAME = 'seoul-shortcuts-v1';
|
||||
const CACHE_NAME = 'seoul-offline-v20260721-nocache1';
|
||||
const CORE_ASSETS = [
|
||||
'./',
|
||||
'./assets/favicon.svg',
|
||||
'./assets/icon-32.png',
|
||||
'./assets/icon-192.png',
|
||||
'./assets/icon-512.png',
|
||||
'./assets/apple-touch-icon.png',
|
||||
'./manifest.webmanifest'
|
||||
];
|
||||
|
||||
self.addEventListener('install', event => {
|
||||
@@ -38,13 +31,5 @@ self.addEventListener('fetch', event => {
|
||||
return;
|
||||
}
|
||||
|
||||
event.respondWith(
|
||||
fetch(event.request)
|
||||
.then(response => {
|
||||
const copy = response.clone();
|
||||
caches.open(CACHE_NAME).then(cache => cache.put(event.request, copy));
|
||||
return response;
|
||||
})
|
||||
.catch(() => caches.match(event.request))
|
||||
);
|
||||
event.respondWith(fetch(event.request, { cache: 'no-store' }));
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user