Skip to content

Commit

Permalink
fix: hash 模式下不修改 output.chunkFilename (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
perzy authored and sorrycc committed May 8, 2019
1 parent 488654a commit 26d1ff0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,10 @@ ${errors.join('\n')}
name: options.htmlName || '[name].[ext]',
});

webpackConfig.output.chunkFilename(`[name].js`);
const { config } = api;
if(!config.hash) {
webpackConfig.output.chunkFilename(`[name].js`);
}

if (options.splitChunks) {
webpackConfig.optimization.splitChunks(
Expand Down

0 comments on commit 26d1ff0

Please sign in to comment.