• Create a new Set with elements that are filtered and transformed by a provided reducer function.

    Parameters

    • reducer: ((arg0, arg1, arg2, arg3) => any)

      A reducer function applied to each value. Positional arguments are the accumulator, the value, the index of iteration, and the set being reduced.

        • (arg0, arg1, arg2, arg3): any
        • Parameters

          • arg0: any
          • arg1: any
          • arg2: number
          • arg3: Set<any>

          Returns any

    • accumulator: any

      The initial value of the returned accumulator.

    Returns any

    The final value of the accumulator.

    See

    Array#reduce