ngFor Directive in Angular: Repeating HTML

preview_player
Показать описание
[15] The Complete Angular Course: ngFor Directive in Angular: Repeating HTML

Build a website from start to finish with Angular.
Learn how to become a full-stack web developer.
Learn how to use the ngFor directive to repeat some of your HTML.

Playlist:

Comment if you have questions. Please like and subscribe for more videos.
Рекомендации по теме
Комментарии
Автор

Do you know how to stop ngFor from rendering empty space for elements in an array if you use ngIf to display a partial amount of array elements in the loop?

For example, I have 5 elements in an array, and I want to display elements 1 to 4, but exclude elements 0 and 5, so I use ngIf to show elements with indexes greater than 0 and less than 5. Where elements 0 and 5 would be are blank spaces if I use this method.

Thanks in advance.

cryptoally