Skip to main content
Module

x/fun/optics.ts>key

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 key
import { key } from "https://deno.land/x/fun@v2.0.0-alpha.6/optics.ts";

Given an optic over a record, focus on a value at a key in that record.

Parameters

key: string

Returns

<U extends Tag, S, A>(first: Optic<U, S, Readonly<Record<string, A>>>) => Optic<Align<U, AffineTag>, S, A>