//IF YOU ARE USING ANGULAR > 2
<ul>
<li *ngFor="let item of items; let i = index">
{{i}} {{item}}
</li>
</ul>
//IF YOU ARE USING ANGULAR = 1
<ul>
<li *ngFor="#item of items; #i = index">
{{i}} {{item}}
</li>
</ul>
<ng-container *ngFor="let product of products;">
<ng-container *ngIf="product.isInStock">
<div class="my-class">
Name: {{product.name}}
</div>
</ng-container>
</ng-container>
<div *ngFor="let item of items">
<span>{{item.name}}</span>
<span>{{item.description}}</span>
</div>