Warp/node_modules/@docsearch/react/dist/esm/stored-searches.d.ts

13 lines
447 B
TypeScript
Raw Permalink Normal View History

2024-01-05 12:14:38 +00:00
import type { StoredDocSearchHit } from './types';
declare type CreateStoredSearchesOptions = {
key: string;
limit?: number;
};
export declare type StoredSearchPlugin<TItem> = {
add: (item: TItem) => void;
remove: (item: TItem) => void;
getAll: () => TItem[];
};
export declare function createStoredSearches<TItem extends StoredDocSearchHit>({ key, limit, }: CreateStoredSearchesOptions): StoredSearchPlugin<TItem>;
export {};