fix(pwa): prevent immutable caching of /sw.js and bust SW registration to v5

This commit is contained in:
Amirul Islam Redwan71
2026-12-06 07:19:47 +06:00
parent 9a9021b9c8
commit 7db3f0e72d
2 changed files with 7 additions and 1 deletions
+1 -1
View File
@@ -445,7 +445,7 @@
<script>
if ('serviceWorker' in navigator) {
window.addEventListener('load', function() {
navigator.serviceWorker.register('/sw.js', { scope: '/' })
navigator.serviceWorker.register('/sw.js?v=5', { scope: '/' })
.then(function(reg) {
console.log('[Aura PWA] Service Worker registered with scope:', reg.scope);
})