UNPKG

streak-calc-math

Version:

Dependency-free calendar-day bucketing and streak math primitives, with an optional Node-only on-disk store. Helper for streak-calc-math.

11 lines (9 loc) 285 B
export interface DiskStore { /** Absolute path of the cache directory (created on import). */ dir: string; has(key: string): boolean; get<T = unknown>(key: string): T | undefined; set<T = unknown>(key: string, value: T): T; } export const store: DiskStore; export default store;