btford/ngmin

Allow customizations

gingermusketeer opened this issue · 1 comments

For the angular project I am working on at the moment we have created a directive definition helper. It is mainly for setting some defaults that are common across all the directives in the project and doing some common linking tasks. It would be great if this tool supported customizations to allow this to work.

the helper api is of the form:

someglobal.directiveBuilder({
  "name": "myDirective",
  "controller": function myDirective($scope){}
});

The controller is directly copied to the config object passed to angular

You can write your own astral pass to annotate the controller property as something annotatable, and then use astral-angular-annotate (a dependency of ngmin) to achieve this.