MCPcopy Index your code
hub / github.com/angular/angular / writeFile

Method writeFile

packages/compiler-cli/test/mocks.ts:51–58  ·  view source on GitHub ↗
(fileName: string, data: string)

Source from the content-addressed store, hash-verified

49 }
50
51 writeFile(fileName: string, data: string): void {
52 const parts = fileName.split('/');
53 const name = parts.pop()!;
54 const entry = this.getEntry(parts);
55 if (entry && typeof entry !== 'string') {
56 entry[name] = data;
57 }
58 }
59
60 assumeFileExists(fileName: string): void {
61 this.writeFile(fileName, '');

Callers 1

assumeFileExistsMethod · 0.95

Calls 2

getEntryMethod · 0.95
popMethod · 0.80

Tested by

no test coverage detected