摘要:
Node.js中,除了直接运行脚本文件输出显示以外,还可以使用 -e 方法,如下所示: 装好Node.js后,打开cmd,直接输入以下即可。 node -e "console.log('Hello CSDN');" 原文链接:https://blog.csdn.net/u012138032/arti 阅读全文
摘要:
getBoundingClientRect可以根据dom的四个边获得与window上边或左边的距离。 const obj = dom.getBoundingClientRect();obj.top = dom的上边距离window上边的距离;obj.bottom = dom的下边距离window上边 阅读全文
摘要:
/\bv?(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)(?:-[\da-z-]+(?:\.[\da-z-]+)*)?(?:\+[\da-z-]+(?:\.[\da-z-]+)*)?\b/ 阅读全文
摘要:
当我修改bug01的时候突然来了一个bug02,而且bug02优先级比bug01高,但是我不能提交未修改完的bug01代码,这个时候可以用git stash把bug01的修改放到暂存区,然后修改完bug02并push后,可以用git stash pop把上一个放到暂存区的代码版本合并到当前工作区代码 阅读全文
摘要:
var str = " 1 sa s "; str = str.replace(/\s/g, ''); 阅读全文
摘要:
function download(filename) { var oReq = new XMLHttpRequest(); oReq.open("GET", "", true); oReq.responseType = "blob"; oReq.onload = function (... 阅读全文
摘要:
@font-face{ font-family: '字体名称随便起'; src: url('../font/字体名称.eot'); src:url('../font/字体名称.woff') format('woff'), url('../font/字体名称.ttf') format('truetype'), url('../fo... 阅读全文
摘要:
记得请求的responsType: 'blob' 阅读全文
摘要:
.doc application/msword .docx application/vnd.openxmlformats-officedocument.wordprocessingml.document .rtf application/rtf .xls application/vnd.ms-exc 阅读全文
摘要:
生成module和routing.module文件 阅读全文