Using *ngFor
you can loop over an array and display contents on the UI
In the TS file
isformes = true;
formsArray = [""];
DelBtn = delIndex => this.formsArray.splice(delIndex, 1);
AddBtn = () => this.formsArray.push("");
HTML FILE
<ng-container *ngFor="let i of formsArray; let j = index">
<div *ngIf="isformes">
<!-- Other staffs here -->
</div>
</ng-container>
CLICK HERE to find out more related problems solutions.