MCPcopy
hub / github.com/dunky11/react-saas-template / isLength

Function isLength

src/shared/functions/toArray.js:757–764  ·  view source on GitHub ↗

* Checks if `value` is a valid array-like length. * * **Note:** This method is loosely based on * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). * * @static * @memberOf _ * @since 4.0.0 * @category Lang * @param {*} value The value to check. * @returns {boolean} Re

(value)

Source from the content-addressed store, hash-verified

755 * // => false
756 */
757function isLength(value) {
758 return (
759 typeof value === "number" &&
760 value > -1 &&
761 value % 1 === 0 &&
762 value <= MAX_SAFE_INTEGER
763 );
764}
765
766/**
767 * Checks if `value` is the

Callers 1

isArrayLikeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected