* Checks if the given key is a valid array index. * @param {string} key - The key to check. * @returns {boolean} - Returns `true` if the key is a valid array index, else `false`.
(key)
| 461 | * @returns {boolean} - Returns `true` if the key is a valid array index, else `false`. |
| 462 | */ |
| 463 | function isArrayIndex(key) { |
| 464 | const keyNum = +key; |
| 465 | if (`${keyNum}` !== key) { return false; } |
| 466 | return keyNum >= 0 && keyNum < 0xFFFF_FFFF; |
| 467 | } |
| 468 | |
| 469 | /** |
| 470 | * Resolves the target of a package based on the provided parameters. |
no outgoing calls
no test coverage detected
searching dependent graphs…