Function iterator

  • Returns Iterator from Iterable and AsyncIterator from AsyncIterable.

    Type Parameters

    • T

    Parameters

    • iter: Iterable<T>

    Returns Iterator<T>

    Example

    // Returns Iterator<number>
    it.iterator([1, 2, 3])