Controller field in a component can accept string, function or an array with parameters an function ["service1","service2", ControllerFunction]

This commit is contained in:
Ugaitz Urien
2016-02-11 16:03:23 +01:00
parent 2d64e0d945
commit ea3fcdda9e

View File

@@ -1685,7 +1685,7 @@ declare module angular {
* Controller constructor function that should be associated with newly created scope or the name of a registered
* controller if passed as a string. Empty function by default.
*/
controller?: string | Function;
controller?: any;
/**
* An identifier name for a reference to the controller. If present, the controller will be published to scope under
* the controllerAs name. If not present, this will default to be the same as the component name.