Function flat

  • Flatten nested array to given depth.

    Parameters

    • x: any[]

      a nested array

    • n: number = -1

      maximum depth [-1 ⇒ all]

    • fm: MapFunction<any, any> = null

      map function (v, i, x)

    • ft: TestFunction<any> = null

      flatten test function (v, i, x) [is]

    Returns any[]

    flat iterable

Generated using TypeDoc