@epic-web/cachified
Version:
neat wrapper for various caches
16 lines (15 loc) • 378 B
TypeScript
import { Cache } from './common';
interface SoftPurgeOpts {
cache: Cache;
key: string;
/**
* Force the entry to outdate after ms
*/
staleWhileRevalidate?: number;
/**
* Force the entry to outdate after ms
*/
swr?: number;
}
export declare function softPurge({ cache, key, ...swrOverwrites }: SoftPurgeOpts): Promise<void>;
export {};