Fix service worker caching index.html causing blank page
This commit is contained in:
parent
b7ee1c0f26
commit
0df5162981
1 changed files with 8 additions and 1 deletions
|
@ -14,7 +14,10 @@ export default defineConfig({
|
||||||
'safari-pinned-tab.svg',
|
'safari-pinned-tab.svg',
|
||||||
'mstile-150x150.png',
|
'mstile-150x150.png',
|
||||||
],
|
],
|
||||||
injectManifest: true,
|
injectManifest: {
|
||||||
|
globPatterns: ['**/*.{js,css,html,png,svg}'],
|
||||||
|
globIgnores: ['index.html'],
|
||||||
|
},
|
||||||
manifest: {
|
manifest: {
|
||||||
name: 'Donetick: Simplify Tasks & Chores, Together.',
|
name: 'Donetick: Simplify Tasks & Chores, Together.',
|
||||||
short_name: 'Donetick',
|
short_name: 'Donetick',
|
||||||
|
@ -55,6 +58,10 @@ export default defineConfig({
|
||||||
background_color: '#ffffff',
|
background_color: '#ffffff',
|
||||||
display: 'standalone',
|
display: 'standalone',
|
||||||
},
|
},
|
||||||
|
workbox: {
|
||||||
|
skipWaiting: true, // Force the waiting service worker to become the active service worker
|
||||||
|
clientsClaim: true, // Take control of uncontrolled clients as soon as the service worker becomes active
|
||||||
|
},
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue