mirror of
https://github.com/Lissy93/dashy.git
synced 2025-12-06 08:34:14 +01:00
🔀 Merge pull request #1902 from he0119/fix/pwa-runtimeCaching
fix(pwa): should always fetch conf.yml first
This commit is contained in:
commit
6e843cfe66
1 changed files with 12 additions and 0 deletions
|
|
@ -337,6 +337,18 @@ module.exports = {
|
|||
/^manifest.*\.js$/, // default value
|
||||
/\.nojekyll$/,
|
||||
/\.gitignore$/,
|
||||
/conf\.yml$/, // ignore config for runtimeCaching
|
||||
],
|
||||
// https://developer.chrome.com/docs/workbox/modules/workbox-build#type-RuntimeCaching
|
||||
runtimeCaching: [
|
||||
{
|
||||
urlPattern: /conf\.yml$/,
|
||||
handler: 'NetworkFirst',
|
||||
options: {
|
||||
cacheName: 'config-cache',
|
||||
networkTimeoutSeconds: 3,
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
|
|
|
|||
Loading…
Reference in a new issue