UNPKG

@m4x1m1l14n/cache

Version:

Lightweight in-memory isomorphic cache implementation with TTL for browser & Node JS written in TypeScript

16 lines (15 loc) 320 B
export interface CacheOptions { /** * Maximum number of items stored in cache */ maxItems?: number; /** * Time in milliseconds in which timer will check for * outdated items */ resolution?: number; /** * Default timeout for added item */ defaultTTL?: number; }