0

I Have an Array that each member of it is, an array of objects. More detail: Picture
I want to use objects in ng-repeater. How do I do this?!

1
  • use nested ng-repeat Commented May 24, 2015 at 9:20

1 Answer 1

2

You can use nested ng-repeat for this.

$scope.storeCar = [
  [ {name: 'abc'}, {name: 'def'} ],
  [ {name: 'ghi'}]
];

And iterate over storeCar like this:

<ul>
  <li ng-repeat="cars in storeCar">
    <ul>
      <li ng-repeat="car in cars">
        {{car.name}}
      </li>
    </ul>
  </li>
</ul>
Sign up to request clarification or add additional context in comments.

9 Comments

@HosseinGanjyar so if it doesn't work, could you insert source code of your storeCar object?
My data isn't it. my data is array of arrays object. please check picture in above question.
@HosseinGanjyar please insert sample of your structure in above jsfiddle and send link upgraded version
my datat is in Link . An array with arrays of objects. I want to show object in a repeater. thanks
@HosseinGanjyar so it's the same with the one I provided above... check my jsfiddle or insert real json data of your object, a code not a picture
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.