0

how exactly do you run ng-annotate from the command line? Im trying to minify angular, angular_routes and my own script.js into one file. Ive tried grunt uglify:app1 but it gives the injection error. My own code works when minified by itself but not when combined with the angular scripts.here is the grunt file

grunt.initConfig({
    ngAnnotate: {
        options: {
            singleQuotes: true,
        },
        app1: {
            files: {
                'min.js': ['angular.js','angular_routes.js','script.js'],

            },
        },


    },
});

grunt.loadNpmTasks('grunt-ng-annotate');

I dont know what the command is to run it.

user718229
  • 524
  • 6
  • 20

1 Answers1

1

Add this to your grunt file:

grunt.registerTask('default', ['ngAnnotate']);

And then just run grunt in the console

Manu Obre
  • 2,254
  • 1
  • 12
  • 12