2020年4月26日
摘要: splice() 方法向/从数组中添加/删除项目,然后返回被删除的项目,该方法会改变原始数组。所以在删除数组某项中,通常是我的优先选择,例如: var arr=[1,2,3,3,4,5,6,3]; arr.splice(2,1); console.log(arr); 输出结果: 然而,如果将其放在f 阅读全文
posted @ 2020-04-26 14:38 效率的九尾 阅读(842) 评论(0) 推荐(0) 编辑
  2020年4月24日
摘要: 对象的长度不能用.length获取,可以用Object.keys获取 var obj = {'id':1,'name':'叶落森','sex':'女'}; var arr = Object.keys(obj); console.log(arr); // ['id','name','sex'] con 阅读全文
posted @ 2020-04-24 11:04 效率的九尾 阅读(2160) 评论(0) 推荐(0) 编辑
  2020年4月8日
摘要: if(echarts1 == undefined){ echarts1 = echarts.init(document.getElementById(id)); }else{ echarts1.clear(); }//创建时,可加入这段代码,可以判断是重新创建还是注销在vue中创建echarts时, 阅读全文
posted @ 2020-04-08 14:58 效率的九尾 阅读(4565) 评论(0) 推荐(0) 编辑
  2020年1月15日
摘要: 第一种可能重定向的地址要URLEncode处理一下 scope=snsapi_base或scope=snsapi_userinfo第二种可能 原因是我们是单页面应用url自带#/在微信里面认为#号后面的参数不被识别 后端开发人员把参数放到跳转 URL地址前面,正确形式是 https://open.w 阅读全文
posted @ 2020-01-15 17:09 效率的九尾 阅读(12270) 评论(0) 推荐(0) 编辑
  2020年1月14日
摘要: ###disabled <button @click="withdrawMoney()" :disabled="submitDisabled">提交</button> <script> export default{ ready(){ this.submitDisabled = false; //初 阅读全文
posted @ 2020-01-14 16:18 效率的九尾 阅读(8854) 评论(1) 推荐(0) 编辑
  2020年1月7日
摘要: 实现这个功能需要用到touch指令,这个是面向vue2.0的touch指令,是基于touchjs(移动端手势库)。 安装以及引入vue-touch npm install vue-touch@next --save //在vue项目中的main.js文件中引入:import VueTouch fro 阅读全文
posted @ 2020-01-07 13:21 效率的九尾 阅读(6352) 评论(0) 推荐(0) 编辑
  2019年12月31日
摘要: 在网页设计在移动端设计的时候有些box里面都是需要放置video的时候,video的时候的层级总是最高的,这个时候就是需要在video的基础上修改属性就可以了,具体的属性如下,大家可以参考参考: <video src="https://hy.v.netease.com/2018/1030/5c9ca 阅读全文
posted @ 2019-12-31 16:54 效率的九尾 阅读(1292) 评论(0) 推荐(0) 编辑
  2019年12月24日
摘要: var userAgent = navigator.userAgent; //取得浏览器的userAgent字符串 var isOpera = userAgent.indexOf("Opera") > -1; //判断是否Opera浏览器 var isIE = userAgent.indexOf(" 阅读全文
posted @ 2019-12-24 10:28 效率的九尾 阅读(251) 评论(0) 推荐(0) 编辑
  2019年12月12日
摘要: methods : { //禁止滚动 stop(){ var mo=function(e){e.preventDefault();}; document.body.style.overflow='hidden'; document.addEventListener("touchmove",mo,fa 阅读全文
posted @ 2019-12-12 16:32 效率的九尾 阅读(662) 评论(1) 推荐(0) 编辑
  2019年12月11日
摘要: document.documentElement.style.fontSize = innerWidth / 7.5 + 'px'; window.onresize = function () { document.documentElement.style.fontSize = innerWidt 阅读全文
posted @ 2019-12-11 11:29 效率的九尾 阅读(551) 评论(0) 推荐(0) 编辑