const array = [1, 2, 3];const index = -5;const normalizedIndex = normalizeIndex(index)(array);console.log(normalizedIndex); // 1
the normalized index, or 0 if the array is empty
0
Generated using TypeDoc
Example
Returns
the normalized index, or
0if the array is empty