UNPKG

tiny-bin

Version:

A library for building tiny and beautiful command line apps.

14 lines (13 loc) 901 B
import stripAnsi from 'ansi-purge'; import { toCamelCase } from 'kasi'; import parseArgv from 'tiny-parse-argv'; declare const castArray: <T>(value: T | T[]) => T[]; declare const getClosest: (values: string[], value: string, maxDistance?: number, caseInsensitive?: boolean) => string | undefined; declare const groupBy: <T, U>(values: T[], iterator: (value: T, index: number, values: T[]) => U) => Map<U, T[]>; declare const identity: <T>(value: T) => T; declare const isArray: (value: unknown) => value is unknown[]; declare const isObject: (value: unknown) => value is object; declare const isUndefined: (value: unknown) => value is undefined; declare const pushBack: <T, U>(map: Map<T, U>, key: T) => Map<T, U>; declare const sum: (numbers: number[]) => number; export { castArray, getClosest, groupBy, identity, isArray, isObject, isUndefined, parseArgv, pushBack, stripAnsi, sum, toCamelCase };