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

Method compile

ark/schema/roots/morph.ts:197–204  ·  view source on GitHub ↗
(js: NodeCompiler)

Source from the content-addressed store, hash-verified

195 }
196
197 compile(js: NodeCompiler): void {
198 if (js.trav === "Allows") {
199 js.return(this.head ? js.inv(this.head) : true)
200 return
201 }
202 if (js.trav === "Transform") return this.jsTf(js)
203 js.return(this.head ? js.applyMember(this.head) : true)
204 }
205
206 private jsTf(js: NodeCompiler): void {
207 let result = "data"

Callers

nothing calls this directly

Calls 3

jsTfMethod · 0.95
returnMethod · 0.80
invMethod · 0.45

Tested by

no test coverage detected