javascript - Performance issue in ngRepeat -


i have ngrepeat block iterates on array of objects draws row accordingly.

one of properties of object string requires transformation before displayed.

performancewise, right run function everytime angular runs loop?

   <div ng-repeat="a in arr">{{ strtransform(a.name) }}</div> 

yes, ok, performance-wise , everything, unless:

  1. your transformation function way expensive, in case you're doomed, or:
  2. you got humongous amount of elements process, in case you're doomed rendering time anyway.

--

as side note, i'd add might wanna use angular filter (link) these kinds of operations :)


Comments

Popular posts from this blog

android - Gradle sync Error:Configuration with name 'default' not found -

java - Andrioid studio start fail: Fatal error initializing 'null' -

html - jQuery UI Sortable - Remove placeholder after item is dropped -