一系列的触发,停止触发(最后一次触发 xx 毫秒后没有再触发)后就执行。延后执行。
xx 秒内只允许执行1次,第一次触发时立即执行。
| [ | |
| { | |
| "name": "ABS", | |
| "category": "Math and trigonometry", | |
| "description": "Returns the absolute value of a number" | |
| }, | |
| { | |
| "name": "ACCRINT", | |
| "category": "Financial", | |
| "description": "Returns the accrued interest for a security that pays periodic interest" |
| # if you remember current password: | |
| mysql -u root -p | |
| set password for 'root'@'localhost' = PASSWORD('your-new-password'); | |
| flush privileges; | |
| # else: | |
| # 1. stop mysql | |
| # 2. | |
| sudo /usr/local/mysql/bin/mysql_safe --skip-grant-tables | |
| # 3. open new terminal tab |
| let elemStyle = document.createElement('style') | |
| elemStyle.innerHTML = ` | |
| h1:hover, | |
| h2:hover, | |
| h3:hover, | |
| h4:hover, | |
| h5:hover, | |
| h6:hover, |
| # 只 clone 最新的代码,不要 commits/tags... | |
| git clone https://xxx/xxx.git --depth 1 | |
| # 这称为 shallow clone | |
| # 如果后面又需要完整的仓库 | |
| git pull --unshallow | |
| # === 恢复数据 === | |
| # reflog 可以查看你每次 git 操作后的 hash | |
| git reflog |
| .top-box { | |
| box-shadow: inset 0 7px 9px -7px rgba(0,0,0,0.7); | |
| } | |
| .left-box { | |
| box-shadow: inset 7px 0 9px -7px rgba(0,0,0,0.7); | |
| } | |
| .right-box { | |
| box-shadow: inset -7px 0 9px -7px rgba(0,0,0,0.7); |
| let domRect = elem.getBoundingClientRect(); | |
| /* | |
| - top: 元素*上边界* 与 页面可视区域*上边界* 的距离; | |
| - bottom: 元素*下边界* 与 页面可视区域*上边界* 的距离; | |
| - right: 元素*右边界* 与 页面可视区域*左边界* 的距离; | |
| - left: 元素*左边界* 与 页面可视区域*左边界* 的距离; | |
| // IE9+ | |
| - width, 元素的宽; | |
| - height, 元素的高; |
| docker rmi $(docker images --filter "dangling=true" -q --no-trunc) | |
| # if you got: "docker rmi" requires at least 1 argument. | |
| # That means you don't have useless <none> images, | |
| # maybe you can remove useless containers before. | |
| # after 1.25, you can use the follow cmd. | |
| # https://docs.docker.com/engine/reference/commandline/image_prune/ | |
| docker image prune |