Im trying to show a div if "avenant" does not exist but its not working !
*ngIf="avenant"
is working it shows the avenants if they exist,
but *ngIf="!avenant"
doesn't show the message in the div !
<ng-container *ngFor="let avenant of Avenants" >
<ng-container *ngIf="avenant">
<div class="panel-body border border-purple rounded stl2">
<table class="table table-hover">
<thead class="thead-light" >
<tr>
<th>id</th>
<th> Actions</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let avenant of Avenants | orderBy: 'id' ">
<td>{{avenant.id}}</td>
<td>
<button class="btn btn-danger" type="button" (click)="deleteAvenantId(avenant.id)> </button>
</td>
</tr>
</tbody>
</table>
</div>
</ng-container>
<ng-container *ngIf="!avenant">
<div>
no avenant found !
</div>
</ng-container>
</ng-container>