Ignore search when caching pages
Boris Kubiak kubiakboris@gmail.com
Fri, 21 Aug 2020 16:45:08 +0200
1 files changed,
1 insertions(+),
1 deletions(-)
jump to
M
sw.js
→
sw.js
@@ -67,7 +67,7 @@ if (!event.request.url.startsWith(self.location.origin) && !event.request.url.startsWith('https://cdn.jsdelivr.net')) {
return; } event.respondWith( - caches.match(event.request).then((cachedResponse) => { + caches.match(event.request, { ignoreSearch: true }).then((cachedResponse) => { if (cachedResponse) { return cachedResponse; }