Skip to content
This repository has been archived by the owner on Aug 8, 2019. It is now read-only.

mangle option for UglifyJsPlugin is true, not false #49

Closed
PinkyJie opened this issue Nov 25, 2015 · 1 comment
Closed

mangle option for UglifyJsPlugin is true, not false #49

PinkyJie opened this issue Nov 25, 2015 · 1 comment

Comments

@PinkyJie
Copy link

In this document, http://webpack.github.io/docs/list-of-plugins.html#uglifyjsplugin.

list_of_plugins

It says By default the mangle option is false., but actully the default mangle option is true. (We can infer this from the subsequent sentence But you can configure the plugin to avoid mangling specific variable names by passing an except list.) I also check the source code of UglifyJSPlugin at https://github.com/webpack/webpack/blob/master/lib/optimize/UglifyJsPlugin.js#L90 :
if(options.mangle !== false) {...}
Unless we explicitly give it a false value, it will still do the mangling thing.

@PinkyJie
Copy link
Author

Seems the latest documentation fixed this issue.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant