I have defined a function on scope. And when I call it from the view inside {{}} it executes X number of times.
Controller
function testCtrl($scope) {
$scope.myFunc = function(name) {
return "Hello " + name;
}
}
HTML
<div>{{myFunc('Joe')}}</div>
You can see it in this example: http://jsfiddle.net/rbRvD/2/
Or with Plunker: http://plnkr.co/edit/LLQ7cKs2fEoBwv0C5XPE
I guess this is done the wrong way, but why is it executed so many times?