ng class conditional typescript function code example Example: Angular 8 ngClass If [ngClass]="(step=='step1')?'my-class1':'my-class2'"