From cb230638bd50075bb8efabbd10f9d4deea89bd30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D0=BD=D1=82=D0=BE=D0=BD=20=D0=A2=D1=80=D0=BE=D1=88?= =?UTF-8?q?=D0=B8=D0=BD?= Date: Sun, 19 Jul 2026 00:08:22 +0300 Subject: [PATCH] store theory files via storage api --- sw.js | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/sw.js b/sw.js index 9ade9e3..fd6c2b8 100644 --- a/sw.js +++ b/sw.js @@ -1,4 +1,4 @@ -const CACHE_NAME = 'numnum-v26'; +const CACHE_NAME = 'numnum-v27'; const ASSETS = [ '/', '/index.html', @@ -9,6 +9,26 @@ const ASSETS = [ '/icon.svg', '/icon-192.png', '/icon-512.png', + '/theory/base3.en.html', + '/theory/base3.ru.html', + '/theory/binary.en.html', + '/theory/binary.ru.html', + '/theory/braille.en.html', + '/theory/braille.ru.html', + '/theory/greek.en.html', + '/theory/greek.ru.html', + '/theory/hebrew.en.html', + '/theory/hebrew.ru.html', + '/theory/hex.en.html', + '/theory/hex.ru.html', + '/theory/octal.en.html', + '/theory/octal.ru.html', + '/theory/roman.en.html', + '/theory/roman.ru.html', + '/theory/slavonic.en.html', + '/theory/slavonic.ru.html', + '/theory/ternary.en.html', + '/theory/ternary.ru.html', ]; self.addEventListener('install', (e) => { @@ -28,7 +48,6 @@ self.addEventListener('activate', (e) => { }); self.addEventListener('fetch', (e) => { - if (e.request.url.includes('/theory/')) return; e.respondWith( caches.match(e.request).then(r => r || fetch(e.request)) );