0

Within my $scope I have a very large, read-only data structure (maybe 3000+ objects in a hierarchy). Since this never changes, and because I want to maximise performance on mobile, I want to tell Angular it can skip looking for changes within this structure within its digest cycle.

Any ideas if/how this can be done?

4

1 回答 1

1

是的,在这里查看bindonce项目。它允许您在不创建手表的情况下绑定字段。

因此,正如您所描述的,不会有任何双向绑定,因此在 $digest 循环中没有脏检查。

于 2013-10-02T14:25:39.727 回答