Skip to main content
Module

x/hkts/type_classes.ts>Monad

Functional programming tools: option, either, task, state, optics, etc.
Latest
interface Monad
implements Applicative<URI, _>, Chain<URI, _>
import { type Monad } from "https://deno.land/x/hkts@v0.0.52/type_classes.ts";

Monad https://github.com/fantasyland/static-land/blob/master/docs/spec.md#monad

Here we extend Monad with a join function. Other names for join are flatten or flat.

Type Parameters

URI extends URIS
optional
_ extends any[] = any[]

Properties

readonly
join: <A, B extends _[0], C extends _[1], D extends _[2]>(tta: Kind<URI,
[
Kind<URI,
[
A,
B,
C,
D,
]
>,
B,
C,
D,
]
>
) => Kind<URI,
[
A,
B,
C,
D,
]
>