I have multiple post data inside an array. I want to render each post. There are two approaches to render :
1: create a reusable component and call it multiple times inside *ngFor
<div *ngFor="let post of posts">
<render-post [post]="post"><render-post>
</div>
2: create a component and pass the array inside the component
<div>
<render-post [posts]="posts"></render-post>
</div>