Function uncurryTuple

  • Transforms the given function of two arguments from curried format to "tuple curried" which can be used with Opt.zip.

    const sub = (x: number) => (y: number) => x - y;
    opt(4) // Some(4)
    .zip(opt(1)) // Some([4, 1])
    .map(uncurryTuple(sub)) // Some(3)

    Type Parameters

    • A

    • B

    • C

    Parameters

    • _: ((_) => ((_) => C))
        • (_): ((_) => C)
        • Parameters

          • _: A

          Returns ((_) => C)

            • (_): C
            • Parameters

              • _: B

              Returns C

    Returns ((_) => C)

      • (_): C
      • Parameters

        • _: [A, B]

        Returns C

Generated using TypeDoc