摘要: 今天在ie浏览器上出现的问题 谷歌浏览器是没有问题的,但是ie浏览器上就会调用两次相同接口 <el-autocomplete v-model="state" :fetch-suggestions="querySearchAsync" placeholder="请输入内容" @select="hand 阅读全文
posted @ 2019-03-13 18:02 你的名字~ 阅读(6272) 评论(0) 推荐(0) 编辑
摘要: 使用Number.prototype.toLocaleString() 阅读全文
posted @ 2019-03-13 17:56 你的名字~ 阅读(2919) 评论(0) 推荐(0) 编辑
摘要: 一、用有意义且常用的单词命名变量 二、直接了当 bad: good: 三、避免无意义的前缀 bad: good: 四、使用默认值 bad: good: 五、参数越少越好 如果参数超过两个,使用 ES2015/ES6 的解构语法,不用考虑参数的顺序。 bad: good: 六、删除重复代码 bad: 阅读全文
posted @ 2019-01-17 16:11 你的名字~ 阅读(243) 评论(0) 推荐(0) 编辑
摘要: // 这是目前用的比较多的方式 // 表示index和test2都使用keep-alive routes: [ { path: '/', redirect: '/index', component: Index, meta: { keepAlive: true }}, { path: '/common', component: TestParent,... 阅读全文
posted @ 2019-01-07 14:22 你的名字~ 阅读(421) 评论(0) 推荐(0) 编辑
摘要: /*手机横屏时执行*/ @media screen and (orientation:landscape){ .txtle{ color: red } } /*手机竖屏时执行*/ @media screen and (orientation:portrait){ #wrap{ display:none; } } 阅读全文
posted @ 2019-01-07 14:15 你的名字~ 阅读(275) 评论(0) 推荐(0) 编辑
摘要: 1 (function (doc, win) { 2 var docEl = doc.documentElement, 3 resizeEvt = 'onorientationchange' in window ? 'onorientationchange' : 'resize', 4 recalc 阅读全文
posted @ 2019-01-07 13:57 你的名字~ 阅读(105) 评论(0) 推荐(0) 编辑
摘要: 1 、添加两个模块 2、定义全局函数,创建一个htmlToPdf.js文件在指定位置.例如放在('src/utils/htmlToPdf') 3、在main.js中使用我们定义的函数文件。 4、在需要的导出的页面..调用我们的getPdf方法即可. js 页面导出PDF文件名 阅读全文
posted @ 2018-12-03 15:37 你的名字~ 阅读(1613) 评论(0) 推荐(0) 编辑
摘要: if (/MicroMessenger/.test(window.navigator.userAgent)) { alert('微信客户端'); } else if (/AlipayClient/.test(window.navigator.userAgent)) { alert('支付宝客户端'); } else { alert('其他浏览器'); } 阅读全文
posted @ 2018-11-28 16:19 你的名字~ 阅读(1096) 评论(0) 推荐(0) 编辑
摘要: 倒计时效果 当前时间: 限时抢购: 阅读全文
posted @ 2018-08-02 17:20 你的名字~ 阅读(322) 评论(0) 推荐(0) 编辑
摘要: npm cache clean --force:先执行这句:npm set registry https://registry.npm.taobao.org:npm set disturl https://npm.taobao.org/dist:npm set sass_binary_site ht 阅读全文
posted @ 2018-07-25 16:48 你的名字~ 阅读(1223) 评论(0) 推荐(0) 编辑