Answer by Mohamed Farouk for How to add styles based on condition
By using [ngClass]. I am not a big fan of inline styles//CSS.myClass{overflow:scroll;height:483px}//Componentexport class MyComponent { public ShowHideSection : boolean = true;}//HTML<div...
View ArticleHow to add styles based on condition
I am trying to add css to my div based on my input checkbox<div class="pvreveal" [style]="ShowHideSection ? 'overflow:scroll;height:483px':''"><input id="isDelivery" type="checkbox"...
View Article
More Pages to Explore .....