MCPcopy Create free account
hub / github.com/InverseUI/InverseUI-Recorder / debounce

Method debounce

modules/action/events/window.js:14–20  ·  view source on GitHub ↗
(func, wait)

Source from the content-addressed store, hash-verified

12 }
13
14 debounce(func, wait) {
15 let timeout;
16 return function(...args) {
17 clearTimeout(timeout);
18 timeout = setTimeout(() => func.apply(this, args), wait);
19 };
20 }
21
22 init() {
23 // Window events

Callers 1

constructorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected