import { Signal, Accessor } from 'solid-js'; import { Pausable } from '@solidjs-use/shared'; interface UseTimestampOptions { /** * Expose more controls * * @default false */ controls?: Controls; /** * Offset value adding to the value * * @default 0 */ offset?: number; /** * Update the timestamp immediately * * @default true */ immediate?: boolean; /** * Update interval, or use requestAnimationFrame * * @default requestAnimationFrame */ interval?: 'requestAnimationFrame' | number; /** * Callback on each update */ callback?: (timestamp: number) => void; } /** * Reactive current timestamp. * * @see https://solidjs-use.github.io/solidjs-use/core/useTimestamp */ declare function useTimestamp(options?: UseTimestampOptions): Signal; declare function useTimestamp(options: UseTimestampOptions): { timestamp: Accessor; } & Pausable; type UseTimestampReturn = ReturnType; export { UseTimestampOptions, UseTimestampReturn, useTimestamp };