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

Function checkFunction

ark/type/runtime.ts:1450–1459  ·  view source on GitHub ↗
(
	value: unknown,
	label: string = unnamed
)

Source from the content-addressed store, hash-verified

1448}
1449
1450export const checkFunction = (
1451 value: unknown,
1452 label: string = unnamed
1453): void => {
1454 if (typeof value !== "function") {
1455 throwError(
1456 writeCreationMismatchMessage(label, describeValue(value), "a function")
1457 )
1458 }
1459}
1460
1461// a value holding a cell a validator reads, set only once its site has run
1462export const checkHeld = (

Callers

nothing calls this directly

Calls 3

throwErrorFunction · 0.90
describeValueFunction · 0.85

Tested by

no test coverage detected