- zipIndex<SecondIterable>(iterableSecond: SecondIterable): SecondIterable extends AsynchronousIterable<SecondItem> ? SecondIterable extends AsyncIterable<SecondItem> ? AsyncIterableIterator<readonly [number, SecondItem]> : IterableIterator<readonly [number, SecondItem]> : never
-
Type Parameters
-
SecondIterable extends AsynchronousIterable<unknown>
Parameters
-
iterableSecond: SecondIterable
Returns SecondIterable extends AsynchronousIterable<SecondItem> ? SecondIterable extends AsyncIterable<SecondItem> ? AsyncIterableIterator<readonly [number, SecondItem]> : IterableIterator<readonly [number, SecondItem]> : never
Yields a tuple for each item in the iterable with the index of said item.
Example
Yields
Tuples with the index of each item.