将JSON对象作为字符串写入新文件,但是使用axios以漂亮的格式编写?

时间:2018-05-10 10:57:43

标签: javascript axios

我在rethinkdb中有数据如下: enter image description here

但现在当我这样做时:

await axios.post(config.baseURL + '/save-menu', {
  filename: rawConfigs[0].repoSettings[0].BaseURL + '/public/log.md' ,
  text:JSON.stringify(job.log),
  type: 'file'
  }).catch((e) => {
   console.log(e)
  )

结果存储如下: enter image description here

我希望它在rethinkdb中看起来很漂亮。

0 个答案:

没有答案