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

Function targetsFrom

__tests__/js-function-local-binding.test.ts:66–69  ·  view source on GitHub ↗
(qualifiedName: string)

Source from the content-addressed store, hash-verified

64});
65
66const targetsFrom = (qualifiedName: string) => {
67 const ids = cg.getNodesInFile('lodash.js').filter((n) => n.qualifiedName === qualifiedName).map((n) => n.id);
68 return cg.getOutgoingEdgesFrom(ids).filter((e) => e.kind !== 'contains').map((e) => cg.getNode(e.target)!.qualifiedName);
69};
70
71describe('JS names the calling function binds', () => {
72 it('are its parameters, not a same-named function elsewhere in the file', () => {

Calls 4

mapMethod · 0.80
getNodeMethod · 0.80
getNodesInFileMethod · 0.65
getOutgoingEdgesFromMethod · 0.45

Tested by

no test coverage detected