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

Method compile

ark/schema/roots/intersection.ts:322–327  ·  view source on GitHub ↗
(js: NodeCompiler)

Source from the content-addressed store, hash-verified

320 }
321
322 compile(js: NodeCompiler): void {
323 if (js.trav === "Allows") this.jsAllows(js)
324 // only a structure can transform an intersection's data
325 else if (js.trav === "Transform") js.return(js.inv(this.structure!))
326 else this.jsApply(js)
327 }
328
329 /** writes its Allows: each child's check, a basis's folded into the first key read */
330 private jsAllows(js: NodeCompiler): void {

Callers 2

checksMethod · 0.45
jsApplyMethod · 0.45

Calls 4

jsAllowsMethod · 0.95
jsApplyMethod · 0.95
returnMethod · 0.80
invMethod · 0.45

Tested by

no test coverage detected