MCPcopy Create free account
hub / github.com/Effect-TS/effect / encodeUnknownExit

Function encodeUnknownExit

packages/effect/src/Schema.ts:2044–2049  ·  view source on GitHub ↗
(schema: S, options?: SchemaAST.ParseOptions)

Source from the content-addressed store, hash-verified

2042 * @since 4.0.0
2043 */
2044export function encodeUnknownExit<S extends ConstraintEncoder<unknown>>(schema: S, options?: SchemaAST.ParseOptions) {
2045 const parser = SchemaParser.encodeUnknownExit(schema, options)
2046 return (input: unknown, options?: SchemaAST.ParseOptions): Exit_.Exit<S["Encoded"], SchemaError> => {
2047 return fromIssueExit(parser(input, options))
2048 }
2049}
2050
2051/**
2052 * Encodes a typed input (the schema's `Type`) against a schema synchronously,

Callers

nothing calls this directly

Calls 1

fromIssueExitFunction · 0.85

Tested by

no test coverage detected