Skip to main content

Function: debounce()

debounce<T>(func, wait, options?): (…args) => void & object
Defined in: throttle.ts:177 Debounce a function to only execute after it stops being called for specified time

Type Parameters

T

T extends AnyFunction

Parameters

func

T Function to debounce

wait

number Wait time in milliseconds

options?

Debounce options

leading?

boolean

maxWait?

number

Returns

(…args) => void & object Debounced function

Example