Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/fun/mod.ts>fn.join

A collection of algebraic data types, lenses, and schemables based on a light weight higher kinded type implementation. Written for deno.
Go to Latest
function fn.join
import { fn } from "https://deno.land/x/fun@v2.0.0-alpha.6/mod.ts";
const { join } = fn;

Collapse a curried function D => D => A into D => A.

Examples

Example 1

import { join } from "./fn.ts";

const add = (n: number) => (m: number) => m + n;
const dup = join(add);

const result1 = dup(1); // 2
const result2 = dup(2); // 4
const result3 = dup(10); // 20

Type Parameters

A
optional
D = unknown

Parameters

tta: Fn<D, Fn<D, A>>