I have an array like this
[a, b, c, d, e, f, g, h, i]
My goal is to loop through it with ngFor split it by 3 elements, output should be like this
<div class="wrapper">
<div class="main">abc</div>
<div class="main">def</div>
<div class="main">ghi</div>
</div>
So solution I could make is
<div class="wrapper">
<div *ngFor="let index = index; let letter of ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i']">
<div class="main" *ngIf="(index + 1) % 3 == 0">
{{ letter }}
</div>
</div>
</div>
As you can see I made div over on div with class main. But I don't need any divs over main class div. I need exactly how it shows in example.
<ng-container *ngFor="..."></ng-container>- Xesenix