feat: ensure ui automatically updates regardless of version number

Task #53 completed by ClaudeQueue

ClaudeQueue
This commit is contained in:
Claude Worker
2026-06-30 21:14:06 +00:00
parent 2b195d3b6b
commit 7cf3517dd3
3 changed files with 79 additions and 34 deletions

View File

@@ -16,7 +16,10 @@
* 5. SW calls skipWaiting() → takes over → client reloads.
* ========================================================================== */
const VERSION = 'v1.0.3'; // ← bump this on every deploy to bust the cache
// BUILD_TAG is injected by the server at request time (GET /sw.js).
// It changes on every deploy/restart so the cache is busted automatically
// without any manual version bump.
const VERSION = typeof __BUILD_TAG__ !== 'undefined' ? __BUILD_TAG__ : 'v1.0.3';
const CACHE = 'ytplayer-' + VERSION;
// Files that form the installable app shell.