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

Only Minify Whitespace on Serverless Builds (#6037)

This commit is contained in:
Connor Davis 2019-01-11 17:15:12 -06:00 committed by GitHub
parent f9efe05d4b
commit 1edd872f54
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -86,7 +86,15 @@ function optimizationConfig ({ dev, isServer, totalPages, target }) {
return {
splitChunks: false,
minimizer: [
new TerserPlugin(terserPluginConfig)
new TerserPlugin({...terserPluginConfig,
terserOptions: {
compress: false,
mangle: false,
module: false,
keep_classnames: true,
keep_fnames: true
}
})
]
}
}