随笔分类 - 前端
摘要:原因是:页面一直在重绘,卡在滚动条刚好出现的位置 当未设定列表宽时,element有做自动检测适应。这造成了一种情况,即上下滚动条的出现时,重置宽度,使得上下滚动条消失,再次触发宽度变换,然后如此循环。 flexbox 子元素设置了 overflow: auto 导致的浏览器 bug 解决办法: h
阅读全文
摘要:####规则 以数字字母开头,中间可以是多个数字字母下划线或‘-’,或‘.’ 然后是 “@”符号,后面是数字字母 然后是“.”符号,后面是2-6个字母结尾 xxxx@xxx.com xxxx@xxx.com.cn xxxx.xxxxx@xxx.com /^([a-zA-Z\d])((\w|-)+\.
阅读全文
摘要:const containerDom = document.querySelector('#container') containerDom.addEventListener('mousedown', function (ev){ let dir=''; let startX=ev.clientX;
阅读全文
摘要:<!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <title>chart</title> </head> <body> <div style="display: flex;"> <div id="chart" style="width:
阅读全文
摘要:使用 cors 跨域 ,后端设置 Access-Control-Allow-Headers 设置 为 ‘*’,移动端浏览器请求失败,PC端请求成功 改成具体值 'content-type,token' 移动端浏览器请求也成功
阅读全文
摘要:// 从url中获取参数 function getParamsFromUrlSearch(search){ if(!search || !(/=/.test(search))){ return undefined; } var arr1 = search.split("&"); var params
阅读全文
摘要:https://www.cnblogs.com/wiliam/p/12587893.html https://www.cnblogs.com/qtiger/p/13207286.html
阅读全文
摘要:https://blog.csdn.net/yellowStar718/article/details/91383925 https://www.cnblogs.com/undefined000/p/vue-nativeApp-development.html 混合开发,页面需要按移动端方式开发,移
阅读全文
摘要:/** * 日期格式化 * @param {string} fmt yyyy-MM-dd hh:mm:ss * @param {Date} date * @returns {string} */ function dateFormat(fmt,date){ if(!date){ date = new
阅读全文
摘要:https://zhuanlan.zhihu.com/p/152097785 https://webpack.js.org/plugins/split-chunks-plugin/#optimizationsplitchunks
阅读全文
摘要:###语法 符号 用法 @param @param {类型} 参数名 描述 @return @return {类型} 返回描述 @author @author 作者 @version @version 版本号 @description @description 描述 /** *@method 方法名
阅读全文
摘要:1、npm 安装 npm -v 查看npm 版本,也可看是否安装成功 npm install npm -g 通过 npm 命令来升级 npm npm install -g cnpm --registry=https://registry.npmmirror.com 使用镜像 npm 可以用 cnpm
阅读全文
摘要:####一:起因 从2017年1月,Google Chrome浏览器首先对HTTP明文协议提出不信任政策,在使用使用HTTP协议的网站,直接在地址栏贴上“不安全”标识,随后各大浏览器都采取相同策略。 ####二: 办法 目前,解决网站的“不安全”标识的最佳解决方案就是:网站通信使用HTTPS 协议。
阅读全文
摘要:1、js 识别 1.1 pc端 和 移动端 代码分开( 各是一个单页应用,或各有一套代码) 直接在 pc端的首页 index.html 的 head 里加入识别代码 <script type="text/javascript"> if(/Android|webOS| iPhone | iPad |
阅读全文
摘要:xx 使用spy-debugger调试微信或者移动端的网页 移动端真机调试 https://www.npmjs.com/package/spy-debugger spy-debugger https://www.cnblogs.com/hongjiahui/p/12736570.html 关于spy
阅读全文
摘要:问题 value-format="yyyy-MM-dd",picker-options设置时间范围失效: 在 Chrome 中正常,开始时间不能早于结束时间,结束时间不能晚于开始时间。但在 Safari 中不能限制 timeStartOptions: { disabledDate: (time) =
阅读全文
摘要:1 function formatNumber1 (number) { const base = 3 number = Number(number) // 只要包含字符 都会转为NaN let numberStr = number.toString() // NaN => 'NaN' if (num
阅读全文
摘要:###elementUI select 下拉框 位置距离太远 调整: https://blog.csdn.net/Hello_yihao/article/details/104557895 <el-select v-model="language" :popper-append-to-body="f
阅读全文
摘要:缓存 缓存技术一直一来在WEB技术体系中扮演非常重要角色,是快速且有效地提升性能的手段。 浏览器缓存分为:强缓存 和 协商缓存 两种 强缓存 强缓存是利用Expires或者Cache-Control这两个http response header实现的,它们都用来表示资源在客户端缓存的有效期。 协商缓
阅读全文
摘要:参考来源:(https://www.jianshu.com/p/e1b01cdc2def) vueCLI:(https://cli.vuejs.org/zh/config/#pages) 多页面,不能共享vuex,状态共享只能传统方式:storage,cookie,URL querystring传值
阅读全文

浙公网安备 33010602011771号