Skip to content

createCache

function createCache(): object

Factory function that created a default cache implementation that uses the nanostores library.

Returns

object

A cache object that satisfies the Cache interface.

get()

get: <T>(key) => Promise<T>;

Type parameters

T

Parameters

key: string

Returns

Promise<T>

set()

set: <T>(key, value) => Promise<void>;

Type parameters

T

Parameters

key: string

value: T

Returns

Promise<void>

Source

utils/dist/index.d.mts:6