MCPcopy Create free account
hub / github.com/arktypeio/arktype / constructor

Method constructor

ark/repo/scratch/typeClass.ts:12–18  ·  view source on GitHub ↗
(input: unknown)

Source from the content-addressed store, hash-verified

10 static infer: type.infer<def>
11
12 constructor(input: unknown) {
13 const out = Validator(input)
14 if (out instanceof type.errors) {
15 return out.throw()
16 }
17 super(out as never)
18 }
19
20 static and<cls extends typeof TypeConstructor<any>, andDef>(
21 this: cls,

Callers

nothing calls this directly

Calls 2

throwMethod · 0.65
ValidatorInterface · 0.50

Tested by

no test coverage detected