Skip to main content
Module

x/fun/mod.ts>schemable.PartialSchemable

A collection of algebraic data types, lenses, and schemables based on a light weight higher kinded type implementation. Written for deno.
Latest
interface schemable.PartialSchemable
implements Hold<U>
import { type schemable } from "https://deno.land/x/fun@v2.0.0/mod.ts";
const { PartialSchemable } = schemable;

Takes a struct of Schemables and returns a Schemable for a struct that matches, key for key, the input schemables but the values can also be partial.

ie. { str: StringSchemable, num: NumberSchemable } becomes Schemable<{ str?: string, num?: number }>

Type Parameters

U extends Kind

Properties

readonly
partial: <A, B, C, D, E>(items: readonly [K in keyof A]: $<U, [A[K], B, C], [D], [E]>) => $<U, [readonly [K in keyof A]?: A[K], B, C], [D], [E]>