UNPKG

@ably/cli

Version:

Ably CLI for Pub/Sub, Chat and Spaces

12 lines (11 loc) 435 B
/** * Finds the closest command ID to the target string from a list of possibilities * using the Levenshtein distance algorithm. * * @param target - The input to find a close match for * @param possibilities - Array of possible matches * @returns The closest match, or empty string if no good match found */ declare const closest: (target: string, possibilities: string[]) => string; export { closest }; export default closest;