Joined November 2012
·
Posted to
AngularJS: Including multiple controllers in a directive.
over 1 year
ago
@paprikkastudio Commonly when forms or form elements are being used. Since ngModel's controller api provides services for data-binding, validation, CSS updates, value formatting and parsing. A directive could require the ngModel controller for validation of an input while also needing to call a method in its parent directives controller.
Here's an example of it being used in the Angular source code: https://github.com/angular/angular.js/blob/master/src/ng/directive/input.js#L1223
Achievements
449 Karma
30,427 Total ProTip Views

Walrus
The walrus is no stranger to variety. Use at least 4 different languages throughout all your repos

Cub
Have at least one original jQuery or Prototype open source repo

Honey Badger
Have at least one original Node.js-specific repo

Mongoose
Have at least one original repo where Ruby is the dominant language

Forked
Have a project valued enough to be forked by someone else

Nephila Komaci
Have at least one original repos where PHP is the dominant language
Great, i'm glad it helped!