Timeline for angularjs controller executes twice
Current License: CC BY-SA 3.0
5 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| May 12, 2017 at 11:50 | comment | added | Alisson Reinaldo Silva |
@dsdsdsdsd When you specify a route, you already configure what is the controller used in the route, so there is no need to add ng-controller to the template (if you are adding the same controller). If you do this, the controller will be executed twice (one due to the route, another due to template).
|
|
| Mar 2, 2016 at 18:54 | comment | added | dsdsdsdsd | ... but having ng-controller within the html element is a fundamental pattern of angular ... its usability is built around that type of notation (identifiers within elements) ... | |
| Oct 15, 2014 at 14:43 | comment | added | Leon Gaban |
Do you mean don't add ng-controller= inside of the template HTML? I'm having the same problem
|
|
| May 27, 2014 at 10:35 | comment | added | iancrowther | great shout, this was exactly the issue for me | |
| Nov 5, 2013 at 15:07 | history | answered | Ivan Koshelev | CC BY-SA 3.0 |