MCPcopy Create free account
hub / github.com/hey-api/hey-api / isNode

Function isNode

packages/codegen-core/src/guards.ts:11–14  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

9}
10
11export function isNode(value: unknown): value is INode {
12 if (!value || typeof value !== 'object') return false;
13 return isBrand(value, nodeBrand);
14}
15
16export function isNodeRef(value: Ref<unknown>): value is Ref<INode> {
17 return isBrand(value['~ref'], nodeBrand);

Callers 7

unwrapFunction · 0.90
fromValueFunction · 0.90
constructorMethod · 0.90
fromValueFunction · 0.90
attrMethod · 0.90
unwrapFunction · 0.90
constructorMethod · 0.90

Calls 1

isBrandFunction · 0.85

Tested by

no test coverage detected