-
-
Notifications
You must be signed in to change notification settings - Fork 179
Support UglifyJS 3 #32
Comments
if u are using yarn, paste the codes below in yarn.lock
Replace the old one, yarn and then it will work, Although it is not recommended to edit in yarn.lock. |
I see this error:
Need to rename to |
|
another way: paste |
@bebraw - Is this something that is currently being worked on? I had a look at the source to see if I could do a PR to support UglifyJS3 but it looks like this is using a lot of undocumented and internal APIs of UglifyJS2 and felt like it would be almost a total rewrite. Maybe @alexlamsl or @kcz could help? |
@ro-savage I don't think anyone is working on this at the moment as people are busy with other things. It's a big rewrite, yeah. |
I created an updated fork two days ago, that has been forked and improved again here https://github.com/Nckcol/uglify-es-webpack-plugin and is now almost feature complete. |
@noBlubb Do you want to look into merging the work back here or do you prefer to maintain it on your own? Webpack main repository has some Uglify tests that have to be ported over and adjusted. |
I would like to transfer the plugin back to webpack-contrib, as I do not feel ready to maintain this all by myself. This started of as some kind of POC for me and I'm happy to give something back to the webpack community :) |
@noBlubb Ok. I guess the question is whether to maintain it as a package of its own or to merge here somehow. I think the overall direction is that we want to get rid of the webpack core version entirely (too coupled). @d3viant0ne Any thoughts on this? |
@nckcol your thoughts? I am happy to help out where I can as well. The uglify-es-webpack-plugin seems to be using only (mainly?) external APIs which makes it easier to get involved with. |
@noBlubb tested your project. Had one issue with Extract Text Plugin.
Error
Had tried
Same result. |
@ro-savage Absolutely! The forked version is as minimal as possible right now. @dlebedynskyi Options are not yet supported, you might want to try @nckcol's fork. |
Hey! I'm working on friendly error and warning output now. @dlebedynskyi I fixed this in my fork |
@bebraw |
@nckcol Are you interested in maintaining the work over here? |
@bebraw Yes, but I'm afraid I will rarely be able to maintain it |
@nckcol No probs, here's a rough roadmap:
There's also webpack core side to worry about as now it comes with a Uglify plugin of its own. I guess we want to drop that in webpack 3 entirely and point people to this plugin instead. Note that we can compensate for maintenance efforts up to a point. I can also invite you to our contrib group (send me mail) so it's easier to discuss the next moves. |
Well, I finished the first item |
Imo you should do an option. In a typical dev setup, uglify is a dependency of a few modules - and if more start using uglify-es then it will be impossible for the consumer to tell this plugin what to use. |
Yeah, we have to keep it flexible so the user can choose between vanilla and ES. It gets more interesting if you want both for some reason, though (can this happen?). Maybe this means the plugin should be able to accept uglify as an option too? @nckcol Please join the Slack when you have time so we can coordinate this work. |
Related: webpack/webpack#5028 |
Closed by #63 |
Currently using UglifyJS 3 breaks the plugin. It has a new API so the plugin has to change accordingly.
The text was updated successfully, but these errors were encountered: