Checks if value is a safe integer. An integer is safe if it's an IEEE-754 double precision number which isn't the result of a rounded unsafe integer.
value
Note: This method is based on Number.isSafeInteger.
Number.isSafeInteger
The value to check.
Returns true if value is a safe integer, else false.
true
false
_.isSafeInteger(3);// => true_.isSafeInteger(Number.MIN_VALUE);// => false_.isSafeInteger(Infinity);// => false_.isSafeInteger('3');// => false Copy
_.isSafeInteger(3);// => true_.isSafeInteger(Number.MIN_VALUE);// => false_.isSafeInteger(Infinity);// => false_.isSafeInteger('3');// => false
Checks if
value
is a safe integer. An integer is safe if it's an IEEE-754 double precision number which isn't the result of a rounded unsafe integer.Note: This method is based on
Number.isSafeInteger
.