( obj )
| 2 | import { isWindow } from "../var/isWindow.js"; |
| 3 | |
| 4 | export function isArrayLike( obj ) { |
| 5 | |
| 6 | var length = !!obj && obj.length, |
| 7 | type = toType( obj ); |
| 8 | |
| 9 | if ( typeof obj === "function" || isWindow( obj ) ) { |
| 10 | return false; |
| 11 | } |
| 12 | |
| 13 | return type === "array" || length === 0 || |
| 14 | typeof length === "number" && length > 0 && ( length - 1 ) in obj; |
| 15 | } |
no test coverage detected