1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-06 02:15:48 +03:00
Files
node-redis/packages/search/lib/commands/SUGGET.ts

23 lines
485 B
TypeScript

export const IS_READ_ONLY = true;
export interface SugGetOptions {
FUZZY?: true;
MAX?: number;
}
export function transformArguments(key: string, prefix: string, options?: SugGetOptions): Array<string> {
const args = ['FT.SUGGET', key, prefix];
if (options?.FUZZY) {
args.push('FUZZY');
}
if (options?.MAX) {
args.push('MAX', options.MAX.toString());
}
return args;
}
export declare function transformReply(): null | Array<string>;