We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9f14df8 commit 8ddb885Copy full SHA for 8ddb885
lib/index.js
@@ -7,7 +7,7 @@ function CssChunkHashPlugin(options) {
7
CssChunkHashPlugin.prototype.createCssHash = function ({ assetsByChunkName, publicPath }) {
8
return Object.keys(assetsByChunkName).reduce((hash, name) => {
9
if (!assetsByChunkName[name] || !assetsByChunkName[name].find) return hash;
10
- const file = assetsByChunkName[name].find(file => file.endsWith('.css'));
+ const file = assetsByChunkName[name].find(file => file.indexOf('.css') >= 0 && file.indexOf('.css.map') < 0);
11
if (file) hash[name] = `${publicPath}${file}`;
12
return hash;
13
}, {});
0 commit comments