Fork me on GitHub

08 2019 档案

摘要:// 丢弃小数部分,保留整数部分 parseInt(5/2) // 2 // 向上取整,有小数就整数部分加1 Math.ceil(5/2) // 3 // 向下取整,丢弃小数部分 Math.floor(5/2) // 2 // 四舍五入 Math.round(5/2) // 3 // 取余 6%4 阅读全文
posted @ 2019-08-29 09:47 欢欢11 阅读(311) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2019-08-28 23:01 欢欢11 阅读(152) 评论(0) 推荐(0) 编辑
摘要:// #ifdef H5 uni.navigateBack({ delta: 2 }); //#endif uni.navigateBack({ delta: 1 }); 如果页面有showModel这类弹窗 uni.navigateBack({}); 跳转不出去 阅读全文
posted @ 2019-08-26 16:32 欢欢11 阅读(2253) 评论(0) 推荐(0) 编辑
摘要://安装: npm install vue-bus1. // app.js var eventBus = { install(Vue,options) { Vue.prototype.$bus = new Vue() } }; Vue.use(eventBus); 2.然后在组件中,可以使用$emit, $on, $off 分别来分发、监听、取消... 阅读全文
posted @ 2019-08-17 09:43 欢欢11 阅读(560) 评论(0) 推荐(0) 编辑
摘要::class="`字符串${index}`" 阅读全文
posted @ 2019-08-15 17:34 欢欢11 阅读(2918) 评论(1) 推荐(0) 编辑

点击右上角即可分享
微信分享提示