You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-07 13:22:56 +03:00
use dockers for tests, use npm workspaces, add rejson & redisearch modules, fix some bugs
This commit is contained in:
22
packages/search/lib/commands/SUGGET.ts
Normal file
22
packages/search/lib/commands/SUGGET.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
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>;
|
Reference in New Issue
Block a user