Skip to content

Commit 19b89eb

Browse files
committed
Barman!
1 parent be2cbed commit 19b89eb

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

template/build/webpack.prod.conf.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,15 @@ const webpackConfig = merge(baseWebpackConfig, {
9595
name: 'manifest',
9696
chunks: ['vendor']
9797
}),
98+
// This instance extracts shared chunks from code splitted chunks and bundles them
99+
// in a separate chunk, similar to the vendor chunk
100+
// see: https://webpack.js.org/plugins/commons-chunk-plugin/#extra-async-commons-chunk
101+
new webpack.optimize.CommonsChunkPlugin({
102+
name: 'app',
103+
async: true,
104+
children: true,
105+
minChnks: 3,
106+
}),
98107
// copy custom static assets
99108
new CopyWebpackPlugin([
100109
{

0 commit comments

Comments
 (0)