js防抖函数的使用

js防抖函数的使用

function debounce(func, delay) { let timer 当前的this是指向window return function (...args) { 当前的this是指向dom元素 if
JavaScript110