Commit d831e6d3 authored by Arunoda Susiripala's avatar Arunoda Susiripala Committed by GitHub

Webpack's ModuleConcatenationPlugin plugin doesn't work well with HMR. (#2584)

So, now we only use it for production.
parent dba24dac
...@@ -131,8 +131,7 @@ export default async function createCompiler (dir, { dev = false, quiet = false, ...@@ -131,8 +131,7 @@ export default async function createCompiler (dir, { dev = false, quiet = false,
}), }),
new PagesPlugin(), new PagesPlugin(),
new DynamicChunksPlugin(), new DynamicChunksPlugin(),
new CaseSensitivePathPlugin(), new CaseSensitivePathPlugin()
new webpack.optimize.ModuleConcatenationPlugin()
] ]
if (dev) { if (dev) {
...@@ -156,6 +155,7 @@ export default async function createCompiler (dir, { dev = false, quiet = false, ...@@ -156,6 +155,7 @@ export default async function createCompiler (dir, { dev = false, quiet = false,
sourceMap: false sourceMap: false
}) })
) )
plugins.push(new webpack.optimize.ModuleConcatenationPlugin())
} }
const nodePathList = (process.env.NODE_PATH || '') const nodePathList = (process.env.NODE_PATH || '')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment