export interface Cancelable { clear(): void; } /** * Creates a throttled function that only invokes `fn` at most once per animation frame. * * @example * ```ts * const throttled = rafThrottle((value: number) => console.log(value)); * window.addEventListener('scroll', (e) => throttled(e.target.scrollTop)); * ``` * * @param fn Callback function * @return The `requestAnimationFrame` throttled function */ export declare function rafThrottle any>(fn: T): T & Cancelable;