摘要:
1、js截取两个字符串之间的内容: varstr = "aaabbbcccdddeeefff"; str = str.match(/aaa(\S*)fff/)[1]; console.log(str);//结果bbbcccdddeee 2、js截取某个字符串前面的内容: varstr = "aaa/ 阅读全文
摘要:
cron的表达式被用来配置CronTrigger实例。 cron的表达式是字符串,实际上是由七子表达式,描述个别细节的时间表。这些子表达式是分开的空白,代表: 1. Seconds 2. Minutes 3. Hours 4. Day-of-Month 5. Month 6. Day-of-Week 阅读全文
摘要:
打开浏览器控制台: var js = window.document.createElement('script'); js.setAttribute('src', 'https://lib.sinaapp.com/js/jquery/2.0.3/jquery-2.0.3.min.js'); js. 阅读全文
摘要:
https://developer.mozilla.org/zh-CN/docs/Web/JavaScript/Reference/Global_Objects/Symbol https://www.jianshu.com/p/fd76d308b742 阅读全文
摘要:
参数默认值 function decimal(num, fix = 2) { return +num.toFixed(fix); } 模板字符串 解构赋值 // 函数入参默认值解构function example({x, y, z = 0}) { return x + y + z; } consol 阅读全文
摘要:
gzip压缩原理 https://segmentfault.com/a/1190000012571492?utm_source=tag-newest //关闭 webpack 的性能提示 https://blog.csdn.net/yun_hou/article/details/87818475 / 阅读全文
摘要:
ES5:(有重复,所以判断数组或对象等,就会有问题) typeof 1 > 'number' typeof 'hello' > 'string' typeof alert > 'function' typeof [1,2,3] > 'object' typeof {a:1,b:2} > 'objec 阅读全文
摘要:
drawText("Hello, World!What a nice day.",0,30,110); function drawText(t,x,y,w){ var chr = t.split(""); var temp = ""; var row = []; context.font = "20 阅读全文
摘要:
彻底搞懂并实现webpack热更新原理 https://segmentfault.com/a/1190000020310371 . 阅读全文
摘要:
示例: <!DOCTYPE html> <html lang="en"> <head> <title>draw curve</title> </head> <!-- https://www.jianshu.com/p/2163fd8f085e --> <!-- http://blogs.sitepo 阅读全文