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

Function route

__tests__/tanstack-router.test.ts:348–352  ·  view source on GitHub ↗
(name: string)

Source from the content-addressed store, hash-verified

346 });
347
348 const route = (name: string): Node => {
349 const r = cg.getNodesByKind('route').find((r) => r.name === name);
350 if (!r) throw new Error(`no route ${name}: ${cg.getNodesByKind('route').map((r) => r.name).join(', ')}`);
351 return r;
352 };
353 const sym = (name: string): Node => {
354 const n = cg.getNodesByName(name).find((n) => n.kind !== 'route' && n.kind !== 'file' && n.kind !== 'import');
355 if (!n) throw new Error(`no symbol ${name}`);

Callers 2

componentOfFunction · 0.70

Calls 3

mapMethod · 0.80
getNodesByKindMethod · 0.65
joinMethod · 0.45

Tested by

no test coverage detected