lms/bootstrap/ssr/assets/debounce-ZFxqVthq.js
2025-12-15 12:26:23 +01:00

15 lines
236 B
JavaScript

function debounce(func, delay) {
let timer;
return function(...args) {
if (timer) {
clearTimeout(timer);
}
timer = setTimeout(() => {
func.apply(this, args);
}, delay);
};
}
export {
debounce as d
};