I am trying to apply the following, is it possible to achieve with ngIf? that it is not necessary to use ngSwitch I would appreciate any help
if(){
}elseif(){
}else{
}
<p *ngIf="document.userDocument.approver1.status == 'Approved';
else pending
">
<nb-icon icon="checkmark-outline"></nb-icon> Approved
</p>
<p *ngIf="document.userDocument.approver1.status == 'Rejected';
else pending
">
<nb-icon icon="close-outline"></nb-icon> Rejected
</p>
<ng-template #pending>
<nb-icon icon="clock-outline"></nb-icon> Pending approval
</ng-template>
Another alternative is to nest conditions