Lodash.toSafeInteger

Converts value to a safe integer. A safe integer can be compared and represented correctly.

_.toSafeInteger(Number.MIN_VALUE); // => 0

_.toSafeInteger(Infinity); // => 9007199254740991

struct Lodash
nothrow @trusted @safe ref
toSafeInteger
()
()

Return Value

Type: auto ref

- Lodash chained on (number): the converted integer.

Meta