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

Method toCodecJson

packages/effect/src/SchemaAST.ts:1428–1436  ·  view source on GitHub ↗

@internal

()

Source from the content-addressed store, hash-verified

1426 }
1427 /** @internal */
1428 toCodecJson(): AST {
1429 if (
1430 this.checks &&
1431 (hasCheck(this.checks, "effect/schema/isFinite") || hasCheck(this.checks, "effect/schema/isInt"))
1432 ) {
1433 return this
1434 }
1435 return replaceEncoding(this, [numberToJson(this.checks)])
1436 }
1437 /** @internal */
1438 toCodecStringTree(): AST {
1439 if (this.toCodecJson() === this) {

Callers 1

toCodecStringTreeMethod · 0.95

Calls 3

hasCheckFunction · 0.85
replaceEncodingFunction · 0.85
numberToJsonFunction · 0.85

Tested by

no test coverage detected