1.循环
<div :class="'default_btn btn_'+(idx)+'' " v-for="(item,idx) in 6" :key="idx">
{{item}}
</div>
2.对象
<div class="static"
:class="{ active: isActive, 'text-danger': hasError }"
></div>
3.数组
:class="[isActive,isSort]"
4.三元表达式
:class="[isActive==index?'active':'otherActiveClass']"
5.数组对象结合动态判断
:class="[{ active: isActive==index }, 'sort']"