UNPKG

rooks

Version:

Essential React custom hooks ⚓ to super charge your components!

17 lines 531 B
declare type CountdownOptions = { interval?: number; onDown?: (restTime: number, newTime: Date) => void; onEnd?: (newTime: Date) => void; }; /** * * useCountdown * Easy way to countdown until a given endtime in intervals * * @param endTime Time to countdown * @param options Countdown options * @see https://react-hooks.org/docs/useCountdown */ declare function useCountdown(endTime: Date, options?: CountdownOptions): number; export { useCountdown }; //# sourceMappingURL=useCountdown.d.ts.map