Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/fun/mod.ts>decoder.Decoder

A collection of algebraic data types, lenses, and schemables based on a light weight higher kinded type implementation. Written for deno.
Go to Latest
type alias decoder.Decoder
import { type decoder } from "https://deno.land/x/fun@v.2.0.0-alpha.11/mod.ts";
const { Decoder } = decoder;

The Decoder<D, A> type represents a function that parses some input D into a value A or a DecodeError. This isn't true parsing of a grammar but instead a combination of refinement and error tracking.

definition: FnEither<D, DecodeError, A>