ngfor max items code example
Example 1: ngfor limit to 10
<li *ngFor="let item of list | slice:0:10; let i=index" class="dropdown-item" (click)="onClick(item)">{{item.text}}</li>
Example 2: ngfor set max number of times
*ngFor="let item of canforgensFeed | slice:0:10;"