is-array-like-x
Determine if a value is array like.
Version: 1.5.0
Author: Xotic750 Xotic750@gmail.com
License: MIT
Copyright: Xotic750
module.exports(value)
⇒ boolean
⏏
Checks if value is array-like. A value is considered array-like if it's
not a function and has a length
that's an integer greater than or
equal to 0 and less than or equal to Number.MAX_SAFE_INTEGER
.
Kind: Exported function
Returns: boolean
- Returns true
if subject is array-like, else false
.
Param | Type | Description |
---|
value | * | The object to be tested. |
Example
var isArrayLike = require('is-array-like-x');
isArrayLike([1, 2, 3]);
isArrayLike(document.body.children);
isArrayLike('abc');
isArrayLike(_.noop);