Fix /set offline cache: save markers and page assets on first visit
Deploy / deploy (push) Successful in 29s

The worker isn't controlling the page on the first visit, so warm-up fetches
bypassed it and no images were cached. The page now writes markers, its own
JS/CSS/fonts and /set/ straight into the cache and only then shows
'Works offline'.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
twotalesanimation
2026-10-06 09:14:33 +02:00
parent ca122ad723
commit e6658eae3d
2 changed files with 30 additions and 10 deletions
+1
View File
@@ -1,5 +1,6 @@
// Offline cache for /set (screen markers). Crews often have no signal on set:
// once the page has loaded once, it and every marker image work offline.
// Must match OFFLINE_CACHE in components/set/MarkerPicker.tsx
const CACHE = "ttvfx-set-v1";
self.addEventListener("install", (event) => {