rankBy beta
Function of @v12-engine/client/kit
ts
export declare function rankBy<T>(items: readonly T[], query: string, textOf: (item: T) => {
label: string;
all?: string;
}, options?: {
fuzzy?: boolean;
threshold?: number;
limit?: number;
}): T[];The items the words typed are found in, the best first (rankWords), those that rank the same in the order they came; those a typo nearly finds last. Every item, as they came, with nothing typed