export declare function literal(o: T): T; export declare function compact(arr: (T | undefined | null)[]): T[]; export declare function last(arr: T[]): T | undefined; /** Returns true if argument is an object (or an array, but NOT null) */ export declare function isObject(o: unknown): o is object; export declare function reduceObj(objs: { [key: string]: V; }, fcn: (memo: R, value: V, key: string, index: number) => R, initialValue: R): R; /** * Concatenate two arrays of values. * This is a convenience function used to ensure that the two arrays are of the same type. * @param arr0 The array of values to push into * @param arr1 An array of values to push into arr0 */ export declare function pushToArray(arr0: T[], arr1: T[]): void; export declare function clone(obj: T): T; export declare function uniq(arr: T[]): T[]; type _Omit = V extends never ? any : Extract extends never ? Partial : Pick>; export declare function omit(obj: V, ...keys: (K | K[])[]): _Omit; export declare function sortBy(arr: T[], fcn: (value: T) => string | number): T[]; export declare function isEmpty(obj: object): boolean; export declare function ensureArray(value: T | T[]): T[]; /** * Slightly faster than Array.isArray(). * Note: Ensure that the value provided is not null! */ export declare function isArray(arg: object | any[]): arg is any[]; /** * Helper function to simply assert that the value is of the type never. * Usage: at the end of if/else or switch, to ensure that there is no fallthrough. */ export declare function assertNever(_value: never): void; export declare function mapToObject(map: Map): { [key: string]: T; }; export declare function compareStrings(a: string, b: string): number; export {}; //# sourceMappingURL=lib.d.ts.map