会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
小凹型
博客园
首页
新随笔
联系
订阅
管理
2022年4月14日
封装sessionStroage和localStorage
摘要: export default { /** * 获取sessionStorage或localStorage中数据 * @param {String} key 存储的键名 * @param {Boolean} isLocal 是否取localStorage */ get(key, isLocal = f
阅读全文
posted @ 2022-04-14 16:08 小凹型
阅读(70)
评论(0)
推荐(0)
2021年9月17日
VUE报错 TypeError: Cannot read property '_wrapper' of undefined
摘要: 先看源码 可以看到是事件问题,我这里问题是click事件没有在method里面定义 然后重新定义一个就好了。
阅读全文
posted @ 2021-09-17 10:06 小凹型
阅读(190)
评论(0)
推荐(0)
2021年9月9日
父组件input框延动态传值给子组件
摘要: 通过自定义的debounce函数和watch监听来做到延迟赋值
阅读全文
posted @ 2021-09-09 16:02 小凹型
阅读(84)
评论(0)
推荐(0)
2021年5月23日
利用filter数组去重
摘要: 利用filter数组去重 var arr = [1, 2, 3, 3, 3, 3, 3, 3, 55, 66, 66, 77, 99, 8, 8, 8, 7, 8]; arr = arr.filter(function(values,index){ return arr.indexOf(values
阅读全文
posted @ 2021-05-23 11:29 小凹型
阅读(503)
评论(0)
推荐(1)
2021年5月9日
JavaScript中逻辑运算符返回值的问题
摘要: 1.||的返回值会返回最早遇到非一下类型的值 NaN null undefined 0 false 就是在碰到结果为True时就会马上返回 比如说: 3||5,则返回3,因为逻辑运算符的运算从最左边开始,所以是返回3 如果||两边都是以上的值时,就会返回最后一个 0||null则会返回null; 2
阅读全文
posted @ 2021-05-09 02:55 小凹型
阅读(271)
评论(0)
推荐(0)
公告