Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

apply

import { apply } from "https://github.gh-proxy.cn/raw.githubusercontent.com/baetheus/fun/main/identity.ts";

Apply a function wrapped in an Identity to a value wrapped in an Identity.

@example
import { apply, wrap } from "./identity.ts";
import { pipe } from "./fn.ts";

const identityFn = wrap((n: number) => n * 2);
const identityValue = wrap(5);
const result = pipe(
  identityFn,
  apply(identityValue)
);

console.log(result); // 10
function apply<A>(ua: Identity<A>): <I>(ufai: Identity<(a: A) => I>) => Identity<I>;
§
apply<A>(ua: Identity<A>): <I>(ufai: Identity<(a: A) => I>) => Identity<I>
[src]

§Type Parameters

§Parameters

§Return Type

§
<I>(ufai: Identity<(a: A) => I>) => Identity<I>
[src]