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

Function configOf

ark/schema/shared/render.ts:123–130  ·  view source on GitHub ↗
(
	error: ArkError,
	slot: ErrorSlot,
	config: ResolvedConfig
)

Source from the content-addressed store, hash-verified

121}
122
123const configOf = (
124 error: ArkError,
125 slot: ErrorSlot,
126 config: ResolvedConfig
127): SlotConfig =>
128 (slot === "message" ? configuredMessageOf(error) : error.meta?.[slot]) ??
129 config[error.code][slot] ??
130 defaultConfig[error.code][slot]
131
132// a discriminant's description lists cases unless its union's own value was described
133const citesDescription = (error: ArkError): boolean =>

Callers 3

writeFunction · 0.70
renderFunction · 0.70
writeInEnFunction · 0.70

Calls 1

configuredMessageOfFunction · 0.90

Tested by

no test coverage detected