UNPKG

@monstermann/fn

Version:

A utility library for TypeScript.

26 lines 470 B
//#region src/number/round.d.ts /** * `round(target)` * * Returns `target` rounded to the nearest integer. * * ```ts * round(4.3); // 4 * round(4.7); // 5 * round(-4.3); // -4 * round(-4.7); // -5 * ``` * * ```ts * pipe(4.3, round()); // 4 * pipe(4.7, round()); // 5 * pipe(-4.3, round()); // -4 * pipe(-4.7, round()); // -5 * ``` */ declare const round: { (): (target: number) => number; (target: number): number; }; //#endregion export { round };