UNPKG

@toreda/time

Version:

Simple, small footprint library for common time operations and converting between units of time.

11 lines (10 loc) 388 B
import type { TimeUnit } from '../unit'; /** * Check if time unit is supported. * @param unit String to validate as supported time unit. * @returns true - Provided `unit` string is a supported time unit. * false - Provided `unit` string is not a supported time unit. * * @category Time Units */ export declare function timeUnitSupported(unit?: TimeUnit): unit is TimeUnit;