We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9d43f3b commit 9a67580Copy full SHA for 9a67580
1 file changed
packages/workbox/lib/options.js
@@ -42,10 +42,10 @@ function getOptions (moduleOptions) {
42
if (!options.assetsURLPattern) {
43
options.assetsURLPattern = joinUrl(options.publicPath, HMRRegex)
44
}
45
- if (options.cacheAssets && !this.options.dev) {
+ if (options.cacheAssets) {
46
options.runtimeCaching.push({
47
urlPattern: options.assetsURLPattern,
48
- handler: 'CacheFirst'
+ handler: this.options.dev ? 'NetworkFirst' : 'CacheFirst'
49
})
50
51
0 commit comments