webpack: don't precache .DS_Store in sw.js (#64)

This commit is contained in:
Olivier Chafik 2024-12-22 22:50:04 +00:00 committed by GitHub
commit a779976038
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -48,6 +48,11 @@ module.exports = [{
}),
...(process.env.NODE_ENV === 'production' ? [
new WorkboxPlugin.GenerateSW({
exclude: [
/\.map$/,
/^manifest.*\.js$/,
/.*?\.DS_Store$/,
],
// these options encourage the ServiceWorkers to get in there fast
// and not allow any straggling "old" SWs to hang around
swDest: path.join(__dirname, "dist", 'sw.js'),