export interface CacheOptions {
    /** Maximum number of items the cache can hold */
    itemLimit: number;
}
/**
 * Create a cache manually. Only useful when you want to specify different options.
 */
export declare function createCache(cacheName: string, options?: Partial<CacheOptions>): void;
/**
 * Use a cache for some arbitrary operation.
 * This is primarily intended for de-duplicating API requests
 * @param cacheName The name of the cache to use, e.g. `'users'`
 * @param key The key for the item in the cache. This can be anything used for the key of a `Map`
 * @param miss The function to run on a cache miss
 * @remarks
 * Note that a cache will automatically be created if it doesn't already exist
 */
export declare function useCache<Key, Result>(cacheName: string, key: Key, miss: () => Result): Result;
