I am looking for a gratis app to minify / obfuscate AngularJs, to make it difficult for anyone to copy & edit it.

Please only recommend something which you have personally used, and trust (I know how to Google :-). This is especially important, because minifying / obfuscating AngularJs is not the same as plain JS.

Preferably something which runs under Windows, but I can use a Linux VM if necessary.

I seek a single click solution, which means that I don’t want to have to make manual edits after each change to the code & obfuscation.

It would be helpful if changes to function names in the controller were also made to the HTML of the view. Otherwise, such names should be unmangled.

1 Answer 1


The easiest way would be to use npm/Gulp:

- package.json
   "babel-polyfill": "^6.9.1",
   "babel-preset-es2015": "^6.9.0",
   "gulp-uglify": "^1.5.4",

- minify.js

    var gulp = require('gulp'),
        pr = gulp.src(folder + '/**/*')
        min = require('gulp-uglify');

        presets: ["es2015"]
    .pipe(gulp.dest(folder + '.min/'));
  • According to npmjs.com/pricing the free version only allows me to "Install and publish open source code in the npm Registry" :-( Jun 7, 2017 at 12:00
  • 2
    But you're not going to sell npm, you just use it for compression. So the license is not valid for you.
    – FieryCat
    Jun 7, 2017 at 12:02
  • So, I am allowed to use NPM for priavte use? Does that include as an installer for s/w whcih I am develoing? Jun 7, 2017 at 12:04
  • 1
    Definitely true.
    – FieryCat
    Jun 7, 2017 at 12:05
  • 1
    We're actively using it... and not only for AngularJS, but also for other frameworks (as ExtJS)
    – FieryCat
    Jun 7, 2017 at 12:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.