微信小程序
Mo_zifeng
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
小程序开发点击真机调试时报错 error: iconPath=xx, file not found
这个错误很佛性,去把文件夹的名字换一下就好了,要是觉得不规范,换了好了之后,再换回来就行。原创 2019-03-08 09:42:00 · 3937 阅读 · 4 评论 -
微信小程序图片宽度100%,高度自适应
实现图片自适应,按照一般情况只需设置: img { width: 100%; height: auto; } 但是微信小程序里是特例,需要image标签上设置属性mode=widthFix,就是height:auto的作用,css同样设置width:100%,如下: image { width: 100%; } <image mode='widt...原创 2019-04-25 15:50:42 · 2173 阅读 · 0 评论 -
微信小程序改变对象属性
在微信小程序里,改变数据需要用setData方法,改变对象如下: this.setData({ obj: {'a':'haha','b':'heihei'} }) 那如果只是想改变的某一个属性值呢,方法有两种: 先用一个变量,接收对象的属性值,再使用setData方法改变 let a = this.data.obj['a']; this.setData({ ...原创 2019-09-28 14:10:45 · 1193 阅读 · 0 评论
分享