A collection of functional utilities for working with results from decoder functions.
import * as D from 'common-decoders';import { pipe, map, fold } from 'common-decoders/utils';const result: string = pipe( 1, D.number, map((n) => n + 1), fold( (error) => `Failed with message ${error}`, (value) => `Got value ${value}` ));
Generated using TypeDoc
A collection of functional utilities for working with results from decoder functions.
Example