/** * Custom hook that provides a requestAnimationFrame-based callback execution. * Useful for performance-critical animations and continuous updates that should * be synchronized with the browser's refresh rate. * * The callback will be executed on the next animation frame, and can be * controlled with an enabled flag for conditional execution. * * @param callback - The function to execute on each animation frame * @param enabled - Whether the animation loop should be active (default: true) * @returns A function to manually trigger the animation frame callback * * @example * ```tsx * const animate = useRaf(() => { * // Animation logic here * console.log('Animation frame') * }, isAnimating) * * // Manually trigger * animate() * ``` */ export declare const useRaf: (callback: VoidFunction, enabled?: boolean) => VoidFunction;