美文网首页
angular [class] [ngStyle]使用

angular [class] [ngStyle]使用

作者: 陈小爬_ | 来源:发表于2019-05-29 16:55 被阅读0次
<a class="downBtn" id="downBtn" href="" download [ngStyle]="{'display': downBtnShow ? 'unset' : 'none' }">下载</a>
[class.selected]='idx===curIdx'
areaColor = 'green';
<div><span [ngStyle]="{'color': areaColor}">{{area}}</span> m²</div>

相关文章

网友评论

      本文标题:angular [class] [ngStyle]使用

      本文链接:https://www.haomeiwen.com/subject/iznytctx.html