一、PubSubJS的使用 工具库: PubSubJS 下载: npm install pubsub-js --save 使用: 1) import PubSub from 'pubsub-js' //引入 2) PubSub.subscribe('delete', function(data){ ...
分类:
其他好文 时间:
2021-04-24 13:38:03
阅读次数:
0
事件捕获 事件捕获中,父级元素先触发,子集元素后触发 事件会从最外层开始,直到具体的元素,比如click的捕获过程document->html->body->div->p 事件冒泡 事件冒泡时,子元素先出发,父级元素后触发 元素自身事件被触发后,如果父元素有相同的事件,那么元素本身的触发状态就会传递 ...
分类:
编程语言 时间:
2021-04-24 13:29:34
阅读次数:
0
转 select *, count(distinct name) from table group by name结果:id name count(distinct name) 1 a 1 2 b 1 3 c 1 最后一项是多余的,不用管就行了,目的达到。原来mysql这么笨,轻轻一下就把他骗过去了 ...
分类:
其他好文 时间:
2021-04-24 11:59:34
阅读次数:
0
SELECT areaName FROM area ORDER BY CONVERT ( areaName USING gbk ) COLLATE gbk_chinese_ci ASC 说明: areaName为列名 area为表名 ...
分类:
数据库 时间:
2021-04-24 11:51:48
阅读次数:
0
1 // 防抖 2 function debounce(func,delay){ 3 let timer = null 4 return function(){ 5 let context = this 6 let args = arguments 7 if(timer) clearTimeout( ...
分类:
Web程序 时间:
2021-04-24 11:51:25
阅读次数:
0
//php获取指定范围内的日期 function periodDate($startDate, $endDate) { $startTime = strtotime($startDate); $endTime = strtotime($endDate); $arr = []; while ($sta ...
分类:
Web程序 时间:
2021-04-23 12:27:28
阅读次数:
0
百度下载QueryList类库文件 /** * 抓取数据源 * @param $rules array 抓取规则 * @param $url string url * @return mixed */ function getQueryList($rules, $url) { $html = fil ...
分类:
Web程序 时间:
2021-04-23 12:26:15
阅读次数:
0
打开Excel文档,按“Alt+F11”进入VBA环境。右击“Microsoft Excel 对象”,从其扩展菜单中选择“插入”-“模块”项。 接着在打开的“模块1”编辑界面中,输入如图所示的代码: Function GetActAddress(HlinkCell) Application.Vola ...
分类:
其他好文 时间:
2021-04-23 12:26:01
阅读次数:
0
webpack配置文件 先看一下webpack的配置文件,刚开始学的时候有点难,配置文件能够完全看懂,说明入门了 // 一个常见的`webpack`配置文件 const webpack = require('webpack'); const HtmlWebpackPlugin = require(' ...
分类:
Web程序 时间:
2021-04-23 12:24:55
阅读次数:
0
function backToTop () { cancelAnimationFrame(timer); // 获取当前毫秒数 const startTime = Date.now(); // 获取当前页面的滚动高度 const scrollTop = document.body.scrollTop ...
分类:
其他好文 时间:
2021-04-23 12:07:09
阅读次数:
0