Conditonal For Loop in Angular JS

uma17
Tera Guru

Hi All,

I want to implement the for loop as below in Angular JS

for(i=0;i<a.length;i++)

How can add the condition i<a.length , where 'a' is   an array.

Thanks,

Uma

3 REPLIES 3

Inactive_Us1474
Giga Guru

Use like this below with ng-repeat attribute :


<div ng-repeat="i in a">{{i}}</div> // where a is an array





Not applicable