Skip to main content
Module

x/fun/state.ts>of

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 of
import { of } from "https://deno.land/x/fun@v.2.0.0-alpha.11/state.ts";

Construct a State<E, A> from a static value A.

Examples

Example 1

import * as S from "./state.ts";

const state = S.of(1);

const result = state(null); // [1, null]

Type Parameters

A
optional
E = unknown