前端Json字符串与Json对象互转
console.log(res.data) //json字符串: "{"fileId":"c32ef043d5124051834e095758411114","originalName":"IMG_20210204_021057.jpg","storePath":"D:\\opt\\www\\iwmp.i56\\upload\\20210204\\c32ef043d5124051834e095758411114.jpg","accessUrl":"http://iwmp.i56/upload/d/20210204/c32ef043d5124051834e095758411114.jpg"}" console.log(JSON.parse(res.data)) // json对象: // { // "fileId": "c32ef043d5124051834e095758411114", // "originalName": "IMG_20210204_021057.jpg", // "storePath": "D:\\opt\\www\\iwmp.i56\\upload\\20210204\\c32ef043d5124051834e095758411114.jpg", // "accessUrl": "http://iwmp.i56/upload/d/20210204/c32ef043d5124051834e095758411114.jpg" // } console.log(JSON.stringify(JSON.parse(res.data))) //json字符串: "{"fileId":"c32ef043d5124051834e095758411114","originalName":"IMG_20210204_021057.jpg","storePath":"D:\\opt\\www\\iwmp.i56\\upload\\20210204\\c32ef043d5124051834e095758411114.jpg","accessUrl":"http://iwmp.i56/upload/d/20210204/c32ef043d5124051834e095758411114.jpg"}"