config/webpack/production.js: Remove caching in OfflinePlugin (introduced in 0692991b5
)
This commit is contained in:
parent
f8cd770a7e
commit
9fab20c069
1 changed files with 1 additions and 30 deletions
|
@ -58,36 +58,7 @@ module.exports = merge(sharedConfig, {
|
|||
plugins: [
|
||||
new OfflinePlugin({
|
||||
publicPath: publicPath, // sw.js must be served from the root to avoid scope issues
|
||||
caches: {
|
||||
main: [':rest:'],
|
||||
additional: [':externals:'],
|
||||
optional: [
|
||||
'**/locale_*.js', // don't fetch every locale; the user only needs one
|
||||
'**/*_polyfills-*.js', // the user may not need polyfills
|
||||
'**/*.woff2', // the user may have system-fonts enabled
|
||||
// images/audio can be cached on-demand
|
||||
'**/*.png',
|
||||
'**/*.jpg',
|
||||
'**/*.jpeg',
|
||||
'**/*.svg',
|
||||
'**/*.mp3',
|
||||
'**/*.ogg',
|
||||
],
|
||||
},
|
||||
externals: [
|
||||
'/emoji/1f602.svg', // used for emoji picker dropdown
|
||||
'/emoji/sheet_10.png', // used in emoji-mart
|
||||
],
|
||||
excludes: [
|
||||
'**/*.map',
|
||||
'stats.json',
|
||||
'report.html',
|
||||
// any browser that supports ServiceWorker will support woff2
|
||||
'**/*.eot',
|
||||
'**/*.ttf',
|
||||
'**/*-webfont-*.svg',
|
||||
'**/*.woff',
|
||||
],
|
||||
caches: {},
|
||||
ServiceWorker: {
|
||||
entry: `imports-loader?ATTACHMENT_HOST=>${encodeURIComponent(JSON.stringify(attachmentHost))}!${encodeURI(path.join(__dirname, '../../app/javascript/mastodon/service_worker/entry.js'))}`,
|
||||
cacheName: 'mastodon',
|
||||
|
|
Loading…
Reference in a new issue