MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / isLength

Function isLength

lib/web/jshint.js:5694–5696  ·  view source on GitHub ↗

* Checks if `value` is a valid array-like length. * * **Note:** This function is based on [`ToLength`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength). * * @private * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value`

(value)

Source from the content-addressed store, hash-verified

5692 * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
5693 */
5694 function isLength(value) {
5695 return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
5696 }
5697
5698 /**
5699 * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.

Callers 15

baseAtFunction · 0.85
baseFlattenFunction · 0.85
baseMapFunction · 0.85
baseMergeFunction · 0.85
baseMergeDeepFunction · 0.85
createBaseEachFunction · 0.85
isIterateeCallFunction · 0.85
shimKeysFunction · 0.85
toIterableFunction · 0.85
runInContextFunction · 0.85
includesFunction · 0.85
sizeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected