MCPcopy Create free account
hub / github.com/Effect-TS/effect / writeJson

Function writeJson

packages/effect/typeperf/run.mjs:34–37  ·  view source on GitHub ↗
(path, value)

Source from the content-addressed store, hash-verified

32const readJson = (path) => JSON.parse(readFileSync(path, "utf8"))
33
34const writeJson = (path, value) => {
35 mkdirSync(dirname(path), { recursive: true })
36 writeFileSync(path, `${JSON.stringify(value, null, 2)}\n`)
37}
38
39const toAbsolute = (path) => resolve(typeperfDir, path)
40

Callers 2

writeTempTsconfigFunction · 0.70
run.mjsFile · 0.70

Calls 1

dirnameFunction · 0.85

Tested by

no test coverage detected