Lens
Lens<
S,A> =object
Defined in: Core/Lens.ts:31
Focuses on a required property or value A inside a parent structure S,
providing a composable way to read, overwrite, and immutably update nested data.
A Lens assumes the target value is guaranteed to exist.
For optional or indexed paths, use Optional<S, A>.
Example
Section titled “Example”Type Parameters
Section titled “Type Parameters”S
A
Properties
Section titled “Properties”
readonlyget: (structure) =>A
Defined in: Core/Lens.ts:31
Parameters
Section titled “Parameters”structure
Section titled “structure”S
Returns
Section titled “Returns”A
readonlyset: (value) => (structure) =>S
Defined in: Core/Lens.ts:31
Parameters
Section titled “Parameters”A
Returns
Section titled “Returns”(structure) => S