hi ketan,

You have misinterpreted the angular document,the symbol ^ means - the 
directive search for controller in current level DOM element directives or 
parent level DOM element directives for any controllers,if it doesn't it 
throws some error, the controller say here is in context to the controller 
which you declare inside the directive,not the on which you declare using 
ng-controller.

so as per the you example the orange searches for any controller in the 
apple directive,since it doesn't find any,its throwing some error.

By the way the controllers in the directives is meant for communicate 
between directives.

Thanks

Regards
Dinesh kumar.L

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to