(filePath: string, data: Record<string, any>)
| 233 | * config no longer has that side effect. |
| 234 | */ |
| 235 | export function writeJsonFile(filePath: string, data: Record<string, any>): void { |
| 236 | backupUnparseableJson(filePath); |
| 237 | atomicWriteFileSync(filePath, JSON.stringify(data, null, 2) + '\n'); |
| 238 | } |
| 239 | |
| 240 | /** |
| 241 | * Compare two JSON values for deep equality, ignoring key order. |
no test coverage detected