1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00

always use write-file-webpack-plugin

This commit is contained in:
nkzawa 2016-10-16 11:49:09 +09:00
parent 3032ade283
commit 3bc8fdecb3

View file

@ -21,14 +21,14 @@ export default async function createCompiler(dir, { hotReload = false } = {}) {
const nodeModulesDir = resolve(__dirname, '..', '..', '..', 'node_modules')
const plugins = hotReload ? [
new webpack.HotModuleReplacementPlugin(),
new WriteFilePlugin({ log: false })
] : [
new webpack.optimize.UglifyJsPlugin({
const plugins = [
hotReload
? new webpack.HotModuleReplacementPlugin()
: new webpack.optimize.UglifyJsPlugin({
compress: { warnings: false },
sourceMap: false
})
}),
new WriteFilePlugin({ log: false })
]
const babelRuntimePath = require.resolve('babel-runtime/package')