UNPKG

@monstermann/fn

Version:

A utility library for TypeScript.

22 lines 464 B
//#region src/map/isEmpty.d.ts /** * `isEmpty(map)` * * Checks if `map` is empty (has no entries). * * ```ts * isEmpty(new Map()); // true * isEmpty(new Map([["a", 1]])); // false * ``` * * ```ts * pipe(new Map(), isEmpty()); // true * pipe(new Map([["a", 1]]), isEmpty()); // false * ``` */ declare const isEmpty: { (): <T, U>(target: ReadonlyMap<T, U>) => boolean; <T, U>(target: ReadonlyMap<T, U>): boolean; }; //#endregion export { isEmpty };