我有我的風格三等功,例如 紅,綠&藍色如何添加類作爲每次迭代次數在循環
顯示在DIV的產品清單,我的要求是要添加的類別按迭代值(按順序)。例如
1st div - red
2nd div - green
3rd div - blue
4th div - red
5th div - green
.
.
(repeat will proceed till last iteration)
(repeat
這裏是我的代碼
<div class="card" ng-repeat="item in circularitems">
<div class="item item-divider circularcard>
<b><span class="ion-ios-compose-outline larger"></span> {{item.notice_title}}</b>
</div>
<div class="item item-text-wrap item-br-color-type-{{$index + 1}}-1">
{{item.notice}} <br><br>
<div class="circular-des-date">Date : {{item.event_date}}</div>
</div>
</div>