/** * Custom hook to debounce a value. The debounced value will only update after the specified delay has passed without any changes. * * @param {string} value - The value to debounce. * @param {number} [delay=1000] - The delay in milliseconds to wait before updating the debounced value. * * @returns {UseDebounceReturn} - The debounced value. * * @example * const debouncedSearchTerm = useDebounce(searchTerm, 500); * * useEffect(() => { * if (debouncedSearchTerm) { * // Perform search * } * }, [debouncedSearchTerm]); */ type UseDebounceReturn = string; declare function useDebounce(value: string, delay?: number): UseDebounceReturn; export { type UseDebounceReturn, useDebounce };