Hi Eric,
The simplest way is to write your own ngRepeat at an higher priority, and
just amend it.
something like this:
function ngRepeat($compile, $parse) {
var ddo = {
restrict: 'A',
priority: 1010,
terminal: true, //stop Compilation
compile: compile
};
return ddo;
function compile(el, attr) {
attr.$set('ngRepeat', attr.ngRepeat + ' track by $index');
var ngModelLink = $compile(el, null, 1010); //restart compilation
at priority 9999
return function(scope) {
ngModelLink(scope); // use the link function from the
compilation
};
}
}
See it in action in this plunk
<http://plnkr.co/edit/RpNr17M3BiFjoakDeYPt?p=preview>
Does that help a bit?
Regards
Sander
--
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.