*ngIf with conditional &&

Asked by At

trying to give *ngIf condition for button, seems I am unable to achieve this below is the code. I am able to show button if I give one conditions but I need to show button on both conditions

<button title="Review" 
*ngIf="pimr.Status === 'success' && pimr.Status === 'failed'" 
class="btn btn-icon" (click)="onAdd()">
<clr-icon shape="eye"></clr-icon>
</button>

1 Answers

0
Community On
  • Since u want to show the buttons on both the conditions , you can use "||" Operator.
  • So that the button can be displayed on either 'success' or 'failed' status.