display data in console using ngfor angular 2 code example Example: ngfor <li *ngFor="let item of items; index as i; trackBy: trackByFn">...</li>