gruntjs / grunt-contrib-uglify

Minify files with UglifyJS.
http://gruntjs.com/
MIT License
1.48k stars 348 forks source link

Doesn't work when compiling certain vendor libraries together #351

Closed HughxDev closed 8 years ago

HughxDev commented 9 years ago

Was trying to use this in an AngularJS project via generator-ngbp, but the compiled JavaScript ultimately choked on the inclusion of stacktrace.js and ui-router-extras, both with the following error:

Uncaught TypeError: angular.module(...).directive(...) is not a function

Those two libraries are not related; they are maintained by different people; one is vanilla JS and the other is an Angular plugin. So I'm wondering if this is an issue that has occurred, or would occur with other libraries. Not sure exactly what causes this as I'm on a work deadline and can't look too closely at it right now.

I previously filed an issue with generator-ngbp but that was the wrong place for it. Is this the right place? Does it belong upstream with uglify proper? Or at stacktrace and ui-router-extras, respectively?

XhmikosR commented 8 years ago

This seems unrelated to grunt-contrib-uglify; try reporting the issue upstream.

mikila85 commented 7 years ago

did you solve it eventually? @hguiney (stuck on the same thing)

HughxDev commented 7 years ago

@mikila85 Filed this last year so I don’t remember. But it looks like I had a deadline to meet so I just excluded the plugins that were causing problems rather than spending a bunch of time trying to get them to work. Sorry I can’t be of more help.

mikila85 commented 7 years ago

Thx anyways :)