会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
--奇--
博客园
首页
新随笔
联系
订阅
管理
[置顶]
draggable拖拽时去除重影阴影
摘要: # draggable拖拽时会出现重影,用户体验不好,需去掉 ``` componentDidMount() { this.dragImg = new Image(0, 0) this.dragImg.src = 'data:image/gif;base64,R0lGODlhAQABAIAAAAAA
阅读全文
posted @ 2023-07-18 14:57 --奇--
阅读(1003)
评论(0)
推荐(0)
[置顶]
调用h5+ 相机方法,并将照片转为base64格式
摘要: 调用h5+ 相机方法,并将照片转为base64格式 plus.camera.getCamera // 调用相机 chooseImage(o) { try { const camera = plus.camera.getCamera(); camera.captureImage(function (p
阅读全文
posted @ 2022-06-15 18:08 --奇--
阅读(810)
评论(0)
推荐(0)
2022年3月16日
Object类型转为query字符串类型
摘要: 将{a: 1, b:2, c:3} 转为a=1&b=2&c=3字符串 function changeQuery(obj) { if (typeof obj !== 'object' || Array.isArray(obj)) return const result = [] for (const
阅读全文
posted @ 2022-03-16 16:10 --奇--
阅读(410)
评论(0)
推荐(0)
2020年9月30日
vue绑定事件需要传递参数,又需要事件参数e
摘要: 在vue项目中,有可能遇到绑定事件时需要传递参数,又需要事件参数e, @click="test($event, '123')" test(e, i){ //e为事件参数 //i为‘123’ }
阅读全文
posted @ 2020-09-30 14:40 --奇--
阅读(914)
评论(0)
推荐(0)
2020年9月29日
js 关于基础数据类型的判空
摘要: 只讨论关于Array, Object的判空 Array, Object变量名只存储一个引用,直接判断肯定不行。 Array直接判断length长度即可判断是否为空。 Object 转变为数组后,在判断length可判空 let temp = {a:1, b:2} 1.let tt = Object.
阅读全文
posted @ 2020-09-29 16:39 --奇--
阅读(288)
评论(0)
推荐(0)
js 日期对象转字符串的各方法汇总
摘要: let today = new Date(); console.log(today.toString()); //Mon Nov 11 2019 11:19:12 GMT+0800 (中国标准时间) console.log(today.toISOString()); //2019-11-11T03:
阅读全文
posted @ 2020-09-29 16:23 --奇--
阅读(408)
评论(0)
推荐(0)
js 字符串的截取
摘要: js 字符串截取方法异同: substr , substring , slice 三个方法都不会改变原数据 当都输入下标时, let temp = 'jiequ' substr为闭合区间,两边都闭合 temp.substr(1) => 'iequ' 下标1开始,一直截到最后 temp.substr(
阅读全文
posted @ 2020-09-29 16:18 --奇--
阅读(297)
评论(0)
推荐(0)
公告