MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / writeJson

Function writeJson

javascript/selenium-webdriver/generate_bidi.mjs:280–284  ·  view source on GitHub ↗
(fileArg, data, label, pretty = false)

Source from the content-addressed store, hash-verified

278}
279
280function writeJson(fileArg, data, label, pretty = false) {
281 const out = resolve(fileArg)
282 writeFileSync(out, pretty ? JSON.stringify(data, null, 2) + '\n' : JSON.stringify(data), 'utf8')
283 console.log(` → ${out} (${label})`)
284}
285
286/** Emit one TS module per domain: types from the AST (cddl2ts), methods from the model. */
287function generateTypeScript(ast, model, args) {

Callers 1

mainFunction · 0.85

Calls 2

resolveFunction · 0.85
logMethod · 0.65

Tested by

no test coverage detected