• Applies the hom X => A => B to another hom X => A.

    Type Parameters

    • X

    Returns (<A, B>(f) => ((g) => Fn<X, B>))

    The applied hom.

    Examples

    import { apply } from "./func.ts";
    import { assertEquals } from "../deps.ts";

    const applier = apply<string>()((str) => (radix: number) =>
    parseInt(str, radix)
    );
    assertEquals(applier(parseInt)("11"), 12);
      • <A, B>(f): ((g) => Fn<X, B>)
      • Type Parameters

        • A

        • B

        Parameters

        • f: Fn<X, ((a) => B)>

        Returns ((g) => Fn<X, B>)

          • (g): Fn<X, B>
          • Parameters

            • g: Fn<X, A>

            Returns Fn<X, B>

Generated using TypeDoc