import type { Ref } from '@stacksjs/stx'; /** * Watch a source with debounced callback invocation. * The callback is only called after the source value has stopped changing * for the specified debounce duration. * * @param source - The reactive source to watch * @param callback - The callback to invoke (debounced) * @param options - Configuration options * @returns A stop function that cleans up both the watch and any pending timer * * @example * ```ts * const search = ref('') * watchDebounced(search, (value) => { * fetchResults(value) * }, { debounce: 300 }) * ``` */ export declare function watchDebounced(source: Ref, callback: (value: T) => void, options?: WatchDebouncedOptions): () => void; export declare interface WatchDebouncedOptions { debounce?: number }