Skip to content

Commit

Permalink
Prioritize order of operations in webpack plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
greenberga committed Sep 23, 2017
1 parent 6b830c4 commit e3a62a9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -264,12 +264,12 @@ module.exports = {
new webpack.optimize.CommonsChunkPlugin({
name: 'vendor',
minChunks({context}) {
if (context) {
const isNodeModule = context.indexOf('node_modules') !== -1;
const isBowerComponent = context.indexOf('bower_components') !== -1;
return isNodeModule || isBowerComponent;
if (!context) {
return false;
}
return false;
const isNodeModule = context.indexOf('node_modules') !== -1;
const isBowerComponent = context.indexOf('bower_components') !== -1;
return isNodeModule || isBowerComponent;
},
}),
new webpack.optimize.CommonsChunkPlugin({name: 'manifest'}),
Expand Down

0 comments on commit e3a62a9

Please sign in to comment.