MCPcopy Create free account
hub / github.com/cloudflare/templates / writeJsonC

Function writeJsonC

cli/src/util.ts:166–168  ·  view source on GitHub ↗
(filePath: string, object: unknown)

Source from the content-addressed store, hash-verified

164}
165
166export function writeJsonC(filePath: string, object: unknown) {
167 fs.writeFileSync(filePath, stringify(object, undefined, 2) + "\n");
168}
169
170export function readJson(filePath: string): unknown {
171 return JSON.parse(fs.readFileSync(filePath, { encoding: "utf-8" }));

Callers 1

lintWranglerJsonCFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected