Skip to content

make UglifyJsPlugin more efficient #1644

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
shai32 opened this issue Feb 26, 2017 · 5 comments
Closed

make UglifyJsPlugin more efficient #1644

shai32 opened this issue Feb 26, 2017 · 5 comments

Comments

@shai32
Copy link

shai32 commented Feb 26, 2017

I think we need to add more compress options in UglifyJsPlugin plugin,
this will result in a more compact build.

my suggestion is:

new webpack.optimize.UglifyJsPlugin({
compress: {
warnings: false,
screw_ie8: true,
conditionals: true,
unused: true,
comparisons: true,
sequences: true,
dead_code: true,
evaluate: true,
if_return: true,
join_vars: true,
},
mangle: {
screw_ie8: true
},
output: {
comments: false,
screw_ie8: true
}
})

@gaearon
Copy link
Contributor

gaearon commented Feb 26, 2017

Send a PR and let's discuss?

@shai32
Copy link
Author

shai32 commented Feb 26, 2017

Ok

@Timer
Copy link
Contributor

Timer commented Mar 7, 2017

@shai32 are you still interested in this? 😄

@shai32
Copy link
Author

shai32 commented Mar 8, 2017

Yes, Still interesting. Hopefully I will do a PR in the weekend

@shai32
Copy link
Author

shai32 commented Mar 24, 2017

All the added options are enabled by default. See UglifyJS documentation.
So we can close this issue

@shai32 shai32 closed this as completed Mar 24, 2017
@lock lock bot locked and limited conversation to collaborators Jan 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants