会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
zhanglw
博客园
首页
新随笔
联系
订阅
管理
上一页
1
···
10
11
12
13
14
15
16
17
18
···
26
下一页
2020年9月11日
window 的 focus 事件 Visibilitychange 事件
摘要: window 的 focus 事件 window.onfocus = function(e) { // 事件处理 } // 或 window.addEventListener('focus', () => { // 事件处理 }, true) 如果打开该页面,然后直接切换浏览器的标签,是不会触发fo
阅读全文
posted @ 2020-09-11 16:50 zhanglw
阅读(2242)
评论(0)
推荐(0)
2020年9月8日
nginx 部署前端项目,不缓存html文件,项目更新,不用手动刷新页面
摘要: location /xxxx{ gzip on; gzip_min_length 1k; #gzip_buffers 4 16k; gzip_http_version 1.1; gzip_comp_level 4; gzip_types text/plain application/javascri
阅读全文
posted @ 2020-09-08 17:56 zhanglw
阅读(5607)
评论(0)
推荐(0)
2020年8月26日
vue 数据双向绑定
摘要: https://www.cnblogs.com/canfoo/p/6891868.html
阅读全文
posted @ 2020-08-26 15:00 zhanglw
阅读(122)
评论(0)
推荐(0)
2020年8月25日
element table 页面连续闪烁抖动
摘要: 原因是:页面一直在重绘,卡在滚动条刚好出现的位置 当未设定列表宽时,element有做自动检测适应。这造成了一种情况,即上下滚动条的出现时,重置宽度,使得上下滚动条消失,再次触发宽度变换,然后如此循环。 flexbox 子元素设置了 overflow: auto 导致的浏览器 bug 解决办法: h
阅读全文
posted @ 2020-08-25 17:51 zhanglw
阅读(3993)
评论(0)
推荐(0)
2020年8月19日
js 验证邮箱
摘要: ####规则 以数字字母开头,中间可以是多个数字字母下划线或‘-’,或‘.’ 然后是 “@”符号,后面是数字字母 然后是“.”符号,后面是2-6个字母结尾 xxxx@xxx.com xxxx@xxx.com.cn xxxx.xxxxx@xxx.com /^([a-zA-Z\d])((\w|-)+\.
阅读全文
posted @ 2020-08-19 17:02 zhanglw
阅读(1006)
评论(0)
推荐(0)
2020年8月14日
移动页面 和 pc 页面 拖拽方向
摘要: const containerDom = document.querySelector('#container') containerDom.addEventListener('mousedown', function (ev){ let dir=''; let startX=ev.clientX;
阅读全文
posted @ 2020-08-14 15:33 zhanglw
阅读(121)
评论(0)
推荐(0)
2020年8月13日
echarts 拖拽数据区动态添加数据
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <title>chart</title> </head> <body> <div style="display: flex;"> <div id="chart" style="width:
阅读全文
posted @ 2020-08-13 17:52 zhanglw
阅读(1044)
评论(0)
推荐(0)
2020年8月4日
移动端页面请求 ajax 跨域 cors 失败
摘要: 使用 cors 跨域 ,后端设置 Access-Control-Allow-Headers 设置 为 ‘*’,移动端浏览器请求失败,PC端请求成功 改成具体值 'content-type,token' 移动端浏览器请求也成功
阅读全文
posted @ 2020-08-04 16:39 zhanglw
阅读(725)
评论(0)
推荐(0)
2020年7月31日
url 参数设置与获取
摘要: // 从url中获取参数 function getParamsFromUrlSearch(search){ if(!search || !(/=/.test(search))){ return undefined; } var arr1 = search.split("&"); var params
阅读全文
posted @ 2020-07-31 10:46 zhanglw
阅读(430)
评论(0)
推荐(0)
2020年7月27日
Vue中使用cdn加载资源
摘要: https://www.cnblogs.com/wiliam/p/12587893.html https://www.cnblogs.com/qtiger/p/13207286.html
阅读全文
posted @ 2020-07-27 16:09 zhanglw
阅读(1890)
评论(0)
推荐(0)
上一页
1
···
10
11
12
13
14
15
16
17
18
···
26
下一页
公告