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

Function readAt

ark/aot/shadow.ts:399–403  ·  view source on GitHub ↗
(t: any, path: string[], args?: unknown[])

Source from the content-addressed store, hash-verified

397 }
398
399const readAt = (t: any, path: string[], args?: unknown[]) => {
400 const holder = path.slice(0, -1).reduce((o, k) => o[k], t)
401 const k = path[path.length - 1]
402 return args ? holder[k](...args) : holder[k]
403}
404
405// binds a method, as describe() selects nodes by `this`
406const boundTo = (target: object, value: unknown) =>

Callers 3

validatorFunction · 0.85
readFunction · 0.85
introspectFunction · 0.85

Calls 1

reduceMethod · 0.80

Tested by

no test coverage detected