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

Function write

__tests__/sync-framework-detection.test.ts:45–48  ·  view source on GitHub ↗
(rel: string, body: string)

Source from the content-addressed store, hash-verified

43 let root: string;
44 let cg: CodeGraph | undefined;
45 const write = (rel: string, body: string) => {
46 fs.mkdirSync(path.dirname(path.join(root, rel)), { recursive: true });
47 fs.writeFileSync(path.join(root, rel), body);
48 };
49 const routes = (rel: string) => cg!.getNodesInFile(rel).filter((n) => n.kind === 'route').map((n) => n.name);
50
51 beforeEach(() => {

Calls 1

joinMethod · 0.45

Tested by

no test coverage detected