@toreda/time
Version:
Simple, small footprint library for common time operations and converting between units of time.
9 lines (8 loc) • 347 B
TypeScript
/**
* Get the current time as a unix timestamp in number form.
* Does not create a Time object.
* @param offset Optional seconds to add or subtract from timestamp. No effect on
* on result when not provided.
* @returns Number of seconds since Unix Epoch.
*/
export declare function unixTimestampNow(offset?: number | null): number;