MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / node

Function node

__tests__/library-method-calls.test.ts:100–101  ·  view source on GitHub ↗
(name: string, file: string)

Source from the content-addressed store, hash-verified

98});
99
100const node = (name: string, file: string) =>
101 cg.getNodesByName(name).find((n) => n.filePath.endsWith(file) && (n.kind === 'function' || n.kind === 'method'))!;
102const calleesOf = (name: string, file: string) =>
103 cg.getCallees(node(name, file).id)
104 .filter(({ edge }) => edge.kind === 'calls')

Callers 1

calleesOfFunction · 0.70

Calls 1

getNodesByNameMethod · 0.65

Tested by

no test coverage detected