
微信小程序
一头萌新
老萌新了
展开
-
Vue条件判断语句
1.v-if的使用删除或创建元素<div id="app"> <h2 v-if="isShow">{{messgae}}</h2></div></body><script>const app = new Vue({ el:"#app", data:{ message:'你好呀' }})</script>2.v-else的使用<div id="app原创 2020-06-30 21:56:19 · 1920 阅读 · 0 评论 -
关于微信小程序蓝牙连接 读写数据 实战
关于微信小程序蓝牙连接 真实记录1. 蓝牙初始化 searchDevice: function() { var that = this //蓝牙是否初始化 wx.openBluetoothAdapter({ success: function(res) { that.getBluetoothState();//获取本机蓝牙适配器状态 }, fail: function(res) { if (res.er原创 2020-06-05 10:19:08 · 8500 阅读 · 9 评论 -
微信小程序 data命名不能大写
data-一切=“{{值}}”这个“一切",不能包含大写<button class='cu-btn round sm bg-blue' catchtap='addShopCart' data-id="{{item.id}}" data-title="{{item.waresName}}"data-saleprice="{{item.salePrice}}" data-image="{{i...原创 2019-08-07 10:24:32 · 339 阅读 · 0 评论 -
微信小程序 下拉刷新
在json 文件中 加“enablePullDownRefresh”: true在wxss文件中 加 背景颜色 不然没有下拉小点点page{background-color: #颜色;}在 js中 加方法onPullDownRefresh() {var that = this;、 var url = ‘一个地址’ wx.showNavigationBarLoading...原创 2019-08-10 09:36:12 · 131 阅读 · 0 评论