MCPcopy
hub / github.com/ajv-validator/ajv / getProperty

Function getProperty

lib/compile/codegen/code.ts:155–157  ·  view source on GitHub ↗
(key: Code | string | number)

Source from the content-addressed store, hash-verified

153}
154
155export function getProperty(key: Code | string | number): Code {
156 return typeof key == "string" && IDENTIFIER.test(key) ? new _Code(`.${key}`) : _`[${key}]`
157}
158
159//Does best effort to format the name properly
160export function getEsmExportName(key: Code | string | number): Code {

Callers 15

multiExportsCodeFunction · 0.90
propertyInDataFunction · 0.90
noPropertyInDataFunction · 0.90
codeFunction · 0.90
dynamicAnchorFunction · 0.90
_dynamicRefFunction · 0.90
validateDiscriminatorFunction · 0.90
getFormatFunction · 0.90
schemaRefOrValFunction · 0.90
setEvaluatedFunction · 0.90
getErrorPathFunction · 0.90
getDataFunction · 0.90

Calls 1

_Function · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…