/** Example: keep only 'fr' in 'fr_FR' */ export declare function shortLang(language: string): string; /** * a polymorphism helper: * accept either a string or an array and return an array */ export declare function forceArray(array: T | readonly T[] | undefined): T[]; /** simplistic implementation to filter-out arrays and null */ export declare function isPlainObject(obj: unknown): boolean; export declare const fixedEncodeURIComponent: (str: string) => string; export declare const replaceSpaceByUnderscores: (str: string) => string; export declare function uniq(array: readonly T[]): T[]; export declare function rejectObsoleteInterface(args: IArguments): void; /** * Checks if the `element` is of one of the entries of `all` * @example const isSite: site is Site = isOfType(sites, site) */ export declare function isOfType(all: readonly T[], element: unknown): element is T; /** key is a key on the object */ export declare function isAKey(obj: Readonly>>, key: PropertyKey): key is T; /** like Object.entries() but with typed keys */ export declare function typedEntries(input: Readonly>>): [K, V][]; /** like Object.keys() but with typed keys */ export declare function typedKeys(obj: Obj): (keyof Obj)[]; export declare function pick>(obj: Obj, keys: string[]): Pick; //# sourceMappingURL=utils.d.ts.map