Skip to content

Commit 89c25fe

Browse files
committed
call $eval in repeater only when needed
when growing children linker calls eval for new nodes, so we need to call it only for reused nodes.
1 parent c06c5a3 commit 89c25fe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/widgets.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -934,6 +934,7 @@ angularWidget('@ng:repeat', function(expression, element){
934934
childScope[valueIdent] = collection[key];
935935
if (keyIdent) childScope[keyIdent] = key;
936936
lastIterElement = childScope.$element;
937+
childScope.$eval();
937938
} else {
938939
// grow children
939940
childScope = createScope(currentScope);
@@ -950,7 +951,6 @@ angularWidget('@ng:repeat', function(expression, element){
950951
lastIterElement = clone;
951952
});
952953
}
953-
childScope.$eval();
954954
index ++;
955955
}
956956
}

0 commit comments

Comments
 (0)