Hi Andre,

If you use a controller, you get a fresh newly instantiated copy. Every 
copy is a "stand alone" version. So if you change some vars in one, it will 
not be reflected in another.
When you need behaviour like this, you should use a service, you inject in 
both controllers. A service is a singleton. that means there is only one 
copy in an AngularJS application.
For more information that explains this, read through the style guide 
<https://github.com/johnpapa/angular-styleguide>. 

Regards
Sander

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" 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 https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to