Defined in: debouncer.ts:6
Options for configuring a debounced function
• TFn extends AnyFunction
• TArgs extends Parameters<TFn>
optional enabled: boolean;
optional enabled: boolean;
Defined in: debouncer.ts:14
Whether the debouncer is enabled. When disabled, maybeExecute will not trigger any executions. Defaults to true.
optional leading: boolean;
optional leading: boolean;
Defined in: debouncer.ts:19
Whether to execute on the leading edge of the timeout. Defaults to false.
optional onExecute: (debouncer) => void;
optional onExecute: (debouncer) => void;
Defined in: debouncer.ts:23
Callback function that is called after the function is executed
Debouncer<TFn, TArgs>
void
optional trailing: boolean;
optional trailing: boolean;
Defined in: debouncer.ts:28
Whether to execute on the trailing edge of the timeout. Defaults to true.
wait: number;
wait: number;
Defined in: debouncer.ts:33
Delay in milliseconds before executing the function Defaults to 0ms
Your weekly dose of JavaScript news. Delivered every Monday to over 100,000 devs, for free.