Skip to content
Buy me a coffee

MemoryCacheStore

Defined in: src/cache.ts:36

In-process store, bounded by maxEntries (least recently used goes first).

new MemoryCacheStore(options?): MemoryCacheStore

Defined in: src/cache.ts:40

number

MemoryCacheStore

get size(): number

Defined in: src/cache.ts:45

number

clear(): void

Defined in: src/cache.ts:70

void


delete(key): void

Defined in: src/cache.ts:66

string

void

CacheStore.delete


get(key): CacheEntry | undefined

Defined in: src/cache.ts:49

string

CacheEntry | undefined

CacheStore.get


set(key, entry): void

Defined in: src/cache.ts:60

ttlMs is how long the entry can still be useful (ttl + staleTtl): remote stores can expire it natively.

string

CacheEntry

void

CacheStore.set