![](https://img-blog.csdnimg.cn/20201014180756919.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
js
Yakiraaa
这个作者很懒,什么都没留下…
展开
-
对象转字符串后使用switch case匹配字符串
【代码】对象转字符串后使用switch case匹配字符串。原创 2023-05-27 14:18:42 · 222 阅读 · 0 评论 -
ThreeJS 移动端点击事件
【代码】ThreeJS 移动端点击事件。原创 2023-02-13 14:38:45 · 289 阅读 · 0 评论 -
正则 显示后六位字符 其余显示星号*
正则 显示后六位字符 其余显示星号*var name = 'abcdefghilklmn'name = name.replace(/.(?=.{6})/g, '*')原创 2022-05-31 19:05:30 · 430 阅读 · 0 评论 -
Echarts遇到的坑总结
Echarts遇到的坑总结legend中标识名称 要和 series 中 name 的值保持一致原创 2022-04-07 17:17:46 · 905 阅读 · 0 评论 -
echarts饼图legend标识位置
echarts图例legend标识位置方式一:只设置left、right、top、bottom具体像素值或百分比legend: { // top: '5%', left: 'center', bottom: 30, //具体像素值或百分比 },方式二:x : 左(left)、右(right)、居中(center)或具体像素值y : 上(top)、下(bottom)、居中(center或具体像素值可使用padding设置距离:padding:[0,0,30,0] (距离上原创 2022-04-06 18:03:01 · 16921 阅读 · 0 评论 -
【uni-app】input框数字限制输入到小数点后两位
//正则表达试 e.target.value = e.target.value.match(/^\d*(\.?\d{0,2})/g)[0] || null; //重新赋值给input this.$nextTick(() => { this.info.price = e.target.value; });原创 2021-05-09 17:31:56 · 1121 阅读 · 0 评论 -
js 遍历对象属性,赋值/添加进另一个对象中
1. 遍历对象属性,相同属性赋值到另一个对象中var dataA = { 'name':'张三', 'age':20, 'sex':'男'}var dataB = { 'name':'李四', 'age':25}for(let k in dataB){ this.dataA[k] = dataB[k];}dataA输出结果:2. 遍历对象属性,添加属性到另一个对象中var dataC = { 'height':'180', 'weight':'160'}Objec原创 2021-05-06 02:26:11 · 9686 阅读 · 0 评论