MCPcopy
hub / github.com/xnimorz/use-debounce / ControlFunctions

Interface ControlFunctions

src/useDebouncedCallback.ts:31–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29}
30
31export interface ControlFunctions<ReturnT> {
32 /**
33 * Cancel pending function invocations
34 */
35 cancel: () => void;
36 /**
37 * Immediately invoke pending function invocations
38 */
39 flush: () => ReturnT | undefined;
40 /**
41 * Returns `true` if there are any pending function invocations
42 */
43 isPending: () => boolean;
44}
45
46/**
47 * Subsequent calls to the debounced function return the result of the last func invocation.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…