ForbesLindesay / browserify-middleware

express middleware for browserify, done right
http://browserify.org
MIT License
381 stars 66 forks source link

Uglifyjs options #26

Closed rnikitin closed 10 years ago

rnikitin commented 10 years ago

Hi guys,

I'm using browserify with angular.js and in production faced bad issue - uglifyjs overwrite angularjs injecting modules definitions. Simular issue is described here http://stackoverflow.com/questions/17238759/angular-module-minification-bug. To avoid this issue we need to disable mungle in uglifyjs:

uglify: {
  options: {
    mangle: false
  }

At the moment I just disable minify in browserify-middleware, but this is not a good solution.

Could you please add the uglifyjs options to browserify-middleware options?