Reducer<T>: ((acc, next, index?, list?) => T)

Type Parameters

  • T

Type declaration

    • (acc, next, index?, list?): T
    • A function called once on each item in an array and returns the accumulated result. The function passes the current accumulated value as the first argument of the next function call.

      Parameters

      • acc: T

        The accumulated result.

      • next: T

        The next item in the array.

      • Optional index: number

        The array index of the next item.

      • Optional list: T[]

        The original array.

      Returns T

Generated using TypeDoc