I have the component and have a problem setting the css class to it. I want it to always have a class of \"box\", then to have additional classes specified by the directive
A quick solution would be define the box class inside ng-class attribute:
If you want to include a scope variable as a class, you can't use ng-class:
Angular expressions do not support the ternary operator, but it can be emulated like this: condition && (answer if true) || (answer if false) 0 讨论(0) 查看其它5个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复
Angular expressions do not support the ternary operator, but it can be emulated like this:
condition && (answer if true) || (answer if false)