effect-io-ai

Package: effect
Module: Schema

Schema.make

Creates a schema from an AST (Abstract Syntax Tree) node.

Details

This is the fundamental constructor for all schemas in the Effect Schema library. It takes an AST node and wraps it in a fully-typed schema that preserves all type information and provides the complete schema API.

The make function is used internally to create all primitive schemas like String, Number, Boolean, etc., as well as more complex schemas. It’s the bridge between the untyped AST representation and the strongly-typed schema.

Signature

declare const make: <S extends Constraint>(ast: S["ast"], options?: object) => S

Source

Since v3.10.0