Avoid unnecessary evaluation of bound values in Angular.js
问题 Have an angular.js directive that renders as a table. Most of the time, the table is small, so performance is not an issue. But sometimes, the table has many rows (e.g. thousands), so rendering every row is expensive, as each bound value appears to be evaluated twice, and there are a lot of bound values. And Angular seems to evaluate this table a lot, only to find that all of the values in it are unchanged and thus need not be rerendered, paralyzing the application needlessly. For instance,