The ability to reply to discussions is limited to PRO members. Want to join in the discussion? Click here to subscribe now.

Using ng-annotate for min-safe AngularJS

Using ng-annotate for min-safe AngularJS

6:03
When you minify your code with a tool like Uglify, the resulting minified file will rename variables. This is a problem for AngualrJS, which uses parameter names to provide injected dependencies. You **could** use the array notation manually, but *no human should ever have to suffer this fate*, **or** you could use [ng-annotate](https://github.com/olov/ng-annotate) with Grunt, and let your helper robots get the job done instead.
Watch this lesson now
Avatar
egghead.io

When you minify your code with a tool like Uglify, the resulting minified file will rename variables. This is a problem for AngualrJS, which uses parameter names to provide injected dependencies. You could use the array notation manually, but no human should ever have to suffer this fate, or you could use ng-annotate with Grunt, and let your helper robots get the job done instead.

HEY, QUICK QUESTION!
Joel's Head
Why are we asking?