vue.js 中 v"/>
vue.js 中 v
<div v-for="(node,index) in circlesTemp" class="bgColorJq":class="(index + 1) % circlesTemp.length == 0 ?'noright':'margin-right-10'":style="{'background-color':node.bgColor}"></div>// 1、在vue中 class 与 :class 是不冲突的,
// 2、(index + 1) % circlesTemp.length == 0 ?'noright':'margin-right-10'" 这格是关键性代码,//样式
<style>.noright{margin-right:0;}.margin-right-10{margin-right:10px;}
</style>
更多推荐
vue.js 中 v
发布评论