fix: add skipWaiting + clientsClaim for immediate SW activation
This commit is contained in:
1 parent
e397591781
commit
058ef497f7
1 file changed
+2
@@ -9,6 +9,8 @@ export default defineConfig({
|
|||||||
VitePWA({
|
VitePWA({
|
||||||
registerType: 'autoUpdate',
|
registerType: 'autoUpdate',
|
||||||
workbox: {
|
workbox: {
|
||||||
|
skipWaiting: true,
|
||||||
|
clientsClaim: true,
|
||||||
globPatterns: ['**/*.{js,css,html,woff,png}'],
|
globPatterns: ['**/*.{js,css,html,woff,png}'],
|
||||||
globIgnores: ['**/data/**'],
|
globIgnores: ['**/data/**'],
|
||||||
maximumFileSizeToCacheInBytes: 20 * 1024 * 1024,
|
maximumFileSizeToCacheInBytes: 20 * 1024 * 1024,
|
||||||
|
|||||||
Reference in new issue
Block a user