@rbxts/pretty-react-hooks
Version:
Useful hooks for @rbxts/react
14 lines (13 loc) • 673 B
TypeScript
import { UseDebounceOptions } from "../use-debounce-callback";
/**
* Creates a debounced effect that delays invoking `effect` until after `wait`
* seconds have elapsed since the last time the debounced function was invoked.
*
* See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
* for details over the differences between `debounce` and `throttle`.
*
* @param effect The effect to debounce.
* @param dependencies The dependencies array.
* @param options The options object.
*/
export declare function useDebounceEffect(effect: () => (() => void) | void, dependencies?: unknown[], options?: UseDebounceOptions): void;