added unit testing, and started implementing unit tests...phew
This commit is contained in:
9
node_modules/is-arrayish/index.js
generated
vendored
Normal file
9
node_modules/is-arrayish/index.js
generated
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
module.exports = function isArrayish(obj) {
|
||||
if (!obj || typeof obj === 'string') {
|
||||
return false;
|
||||
}
|
||||
|
||||
return obj instanceof Array || Array.isArray(obj) ||
|
||||
(obj.length >= 0 && (obj.splice instanceof Function ||
|
||||
(Object.getOwnPropertyDescriptor(obj, (obj.length - 1)) && obj.constructor.name !== 'String')));
|
||||
};
|
Reference in New Issue
Block a user