在微信小程序中 使用uView rules 表单校验 validator 不起作用(无效)
注意,如果需要兼容微信小程序,最好通过setRules方法设置rules规则onReady() {// 如果需要兼容微信小程序,并且校验规则中含有方法等,只能通过setRules方法设置规则this.$refs.form1.setRules(this.rules)},...
·
注意,如果需要兼容微信小程序,最好通过setRules方法设置rules规则
onReady() {
// 如果需要兼容微信小程序,并且校验规则中含有方法等,只能通过setRules方法设置规则
this.$refs.form1.setRules(this.rules)
},
- 在富文本中修改 图片样式,防止图片过大,显示半张的情况
this.produceInfo.description = this.produceInfo.description.replace(/\<img/gi,
'<img class="rich-img" ');;
/* 注意使用 样式穿透 */
.fuji{
& /deep/ rich-img{
max-width:100%;
}
}
更多推荐
已为社区贡献6条内容
所有评论(0)