iterate over chunks of an array using ng-repeat

后端 未结 3 1498
离开以前
离开以前 2020-12-19 19:39

My controller grabs people from the server:

$scope.people = [person1, person2, person3, person4, person5,...]

My template needs to display

3条回答
  •  无人及你
    2020-12-19 20:03

    After years of angular experience, It's obvious that the best way to do this is to split the array into chunks in the controller. Each time the original array is modified, update the chunked array.

提交回复
热议问题