摘要: 1. 声明变量 //Longhandlet x;let y = 20;//Shorthandlet x, y = 20; 2. 给多个变量赋值我们可以使用数组解构来在一行中给多个变量赋值。 //Longhandlet a, b, c;a = 5;b = 8;c = 12;//Shorthandlet 阅读全文
posted @ 2021-02-05 09:18 悟空dong 阅读(91) 评论(0) 推荐(0) 编辑
摘要: 1. css 一行文本超出... overflow: hidden;text-overflow:ellipsis;white-space: nowrap; 2.多行文本超出显示... display: -webkit-box;-webkit-box-orient: vertical;-webkit- 阅读全文
posted @ 2021-02-05 09:15 悟空dong 阅读(67) 评论(0) 推荐(0) 编辑
摘要: 根据需求默认底部导航无法完成 故使用自定义tabBar(底部导航) 1、首先 app.json文件 找到 tabBar 添加 "custom": true 开启自定义tabBar ​ 2、根目录下新建custom-tab-bar目录 新建index(Component组件)**必须是index命名 阅读全文
posted @ 2020-12-01 11:13 悟空dong 阅读(4129) 评论(0) 推荐(0) 编辑
摘要: 相对于H5 音乐播放大家都很熟悉 也是很简单 <audio id="musicfx" loop="loop" preload src="img/First Girl.mp3"></audio> 如果想要自动播放呢 加上 autoplay="autoplay"即可 ! 但是会出现个问题: ios系统的 阅读全文
posted @ 2020-10-09 11:14 悟空dong 阅读(657) 评论(0) 推荐(0) 编辑
摘要: 使用echarts npm install echarts --save || cnpm install echarts --save 定义wkCharts.vue <template> <div :class="className" :style="{height:height,width:wid 阅读全文
posted @ 2020-08-31 15:21 悟空dong 阅读(310) 评论(0) 推荐(0) 编辑
摘要: watch 实现监听数据改变 使用方法 watch:{ data (n, m) { n: 变更后的数据 m:变更前的数据 } } 以上方法 只有在数据发生改变的时候 才能监听到 这个时候 提供了参数 immediate 立即执行监听内的函数 使用方法 watch:{ data (n, m) { n: 阅读全文
posted @ 2020-08-31 14:53 悟空dong 阅读(6814) 评论(0) 推荐(0) 编辑
摘要: //httpService.jsconst host = 'https://baidu.com/ceshi' // 接口请求的域名 // get请求使用 json对象转字符串 (formatParams ) const formatParams = (data) => { let arr = [] 阅读全文
posted @ 2020-08-28 16:19 悟空dong 阅读(1345) 评论(0) 推荐(0) 编辑
摘要: H5 关闭浏览器 function win_close () { // 判断是否支持WeixinJSBridge 微信环境 if (typeof WeixinJSBridge !== 'undefined') { WeixinJSBridge.call('closeWindow')// 微信自带的关 阅读全文
posted @ 2020-08-27 11:19 悟空dong 阅读(2178) 评论(0) 推荐(0) 编辑
摘要: 微信小程序 获取手机号 // 授权手机号 需要button标签 注意:open-type 的值 必须是getPhoneNumber <button open-type="getPhoneNumber" bindgetphonenumber="getuserinfo">授权登录</button> ge 阅读全文
posted @ 2020-08-26 17:37 悟空dong 阅读(379) 评论(0) 推荐(0) 编辑
摘要: 1.公众号 生成带参数的二维码 扫码带参数进入关注公众号页面 官方文档:https://developers.weixin.qq.com/doc/offiaccount/Message_Management/Receiving_event_pushes.html 临时二维码请求说明 http请求方式 阅读全文
posted @ 2020-08-25 11:49 悟空dong 阅读(1594) 评论(0) 推荐(0) 编辑