mirror of
https://github.com/purocean/yn.git
synced 2026-09-24 15:46:02 +08:00
配置保存美化json输出
This commit is contained in:
+1
-1
@@ -4,7 +4,7 @@ const path = require('path')
|
||||
const configFile = path.join(__dirname, '../', 'config.json')
|
||||
|
||||
const writeJson = data => {
|
||||
fs.writeFileSync(configFile, JSON.stringify(data), 'utf8');
|
||||
fs.writeFileSync(configFile, JSON.stringify(data, null, 4), 'utf8');
|
||||
}
|
||||
|
||||
const readJson = () => {
|
||||
|
||||
Reference in New Issue
Block a user