angularjs - Parent directive accessing child directive function -
angularjs - Parent directive accessing child directive function -
let's have 2 directives:
<navigation-extended> <navigation /> </navigation-extended>
navigation-extended html template uses transclude property on div insert basic navigation. besides that, navigation-extended contains html (controls navigate).
what best way access kid functionalities within parent directive?
things i've tried: -require ->using able access navigation-extended methods within navigation not other way around
i think best way accomplish using $broadcast
fire event in parent directive , using $on
handle in kid directive, more info check reply http://stackoverflow.com/a/14502755/158421
angularjs angularjs-directive
Comments
Post a Comment