I would like to use a directive specific controller and the parent controller in the link function.
module.directive('parent', function() {
return {
...
controller: SomeFunction
}
}
module.directive('child', function() {
return {
...
require('^parent'),
controller: SomeOtherFunction,
link: function(scope, element, attr, ctrl) {
//ctrl is the parent controller not the SomeOtherFunction
}
}
}
Is there a way I can use directiveSpecificController but also have access to the parent controller?