Answer the question
In order to leave comments, you need to log in
Apply filter in ngClass?
Is it possible to pass the following logic to ngClass:
If the line variable is true, then display the css class mt20, if not, then do nothing
Example
ng-class="mt20|line"
Where mt20 is a css class (not an angular variable), and line is boolian variable angular
Answer the question
In order to leave comments, you need to log in
<div ng-class="{mg20: line}">
read the documentation for your tools.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question