Skip to content
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

🙋 Configuring uglify #273

Closed
chee opened this issue Dec 14, 2017 · 2 comments · Fixed by #287
Closed

🙋 Configuring uglify #273

chee opened this issue Dec 14, 2017 · 2 comments · Fixed by #287

Comments

@chee
Copy link

chee commented Dec 14, 2017

🙋 🙋 🙋 🙋 🙋 🙋 🙋 🙋 🙋 🙋 🙋 🙋 feature request

I have a problem. When uglify was trouble, I was minifying the code myself after the build step, which was fine. But now I've updated to newer Parcel, and would like to have it take care of the minification for me. However, the top-level mangle is causing issues with this particular codebase.

If this were something in babel or in postcss, i could sneak into their .rc files and make my choices, but uglify doesn't have any kind of an .uglifyrc so I'm locked out of this part of the process.

💁 Possible Solution

@DeMoorJasper suggested we could pretend there was such a thing as an .uglifyrc and process that, which seems pretty good but is certainly unorthodox. It would be nice for this not to be a configuration option for parcel, but for it to be tied (in essence at least) to uglify itself.

@DeMoorJasper DeMoorJasper changed the title Configuring uglify 🙋 Configuring uglify Dec 15, 2017
@davidnagli
Copy link
Contributor

@chee @DeMoorJasper What would be the syntax / available options for this new .uglifyrc?

@brandon93s
Copy link
Contributor

brandon93s commented Dec 17, 2017

uglify already supports a --config-file CLI option to pass JSON as the options for minify(). Presumably, all options would be supported if they map to the options object correctly.

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

Successfully merging a pull request may close this issue.

4 participants