isFinite source npm

_.isFinite(value)

Checks if value is a finite primitive number.

Note: This method is based on Number.isFinite.

Arguments

  1. value (*)

    The value to check.

Returns (boolean)

Returns true if value is a finite number, else false.

Example

_.isFinite(3);
// => true

_.isFinite(Number.MAX_VALUE);
// => true

_.isFinite(3.14);
// => true

_.isFinite(Infinity);
// => false