weex vue text组件动态绑定class无效
2018-11-02 本文已影响0人
樱yuan
在weex构建的项目中使用text组件时,动态绑定class,发现class有添加上去,但是样式并没有应用到,因为使用了传给 v-bind:class 一个对象的动态绑定的方式`
页面代码

在浏览器上的效果

解决方法:
使用把数组传给 v-bind:class的方式

在浏览器上的效果

在weex构建的项目中使用text组件时,动态绑定class,发现class有添加上去,但是样式并没有应用到,因为使用了传给 v-bind:class 一个对象的动态绑定的方式`
页面代码
解决方法:
使用把数组传给 v-bind:class的方式