function debounce (handle,delay){ var timer = null; return function () { clearTimeout(timer) timer = setTimeout(() => { handle.apply(this, arguments) },delay) }}利用了闭包和定时器来延缓函数的执行,最常见的就是应用在input框中