function debounce (handle, delay) {
let timer = null
return function () {
let _this = this, args = arguments;
clearTimeout(timer)
timer = setTimeout(function () {
handle.apply(_this, args)
}, delay)
}
}
function debounce (handle, delay) {
let timer = null
return function () {
let _this = this, args = arguments;
clearTimeout(timer)
timer = setTimeout(function () {
handle.apply(_this, args)
}, delay)
}
}