Skip to content

Commit

Permalink
prod css chunks fix
Browse files Browse the repository at this point in the history
  • Loading branch information
maxgram committed Jul 12, 2017
1 parent 888e3bb commit e482cad
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions config/webpack/config.com.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ const common = {
new webpack.optimize.CommonsChunkPlugin({
name: 'vendor',
minChunks: function (module) {
if(module.resource && (/^.*\.(css)$/).test(module.resource)) {
return false
}
// modules under node_modules are bundled into vendor.js
return module.context && module.context.indexOf('node_modules') !== -1;
}
Expand Down

0 comments on commit e482cad

Please sign in to comment.