• Creates a new iterable with the results of calling a provided function on every element in the calling array. Similar to the Array.prototype.map function. See the documentation of the above function for more details.

    Type Parameters

    • TIn
    • TOut

    Parameters

    • iterable: Iterable<TIn>

      Iterable on which to call the map function.

    • callbackFn: ((element: TIn, index: number) => TOut)

      Function that is called for every element.

        • (element, index): TOut
        • Parameters

          • element: TIn
          • index: number

          Returns TOut

    • OptionalthisArg: unknown

      Value to use as this when executing callbackFn.

    Returns Iterable<TOut>