Convert res into JSON format?
OR
2 Convert JSON format into JS Object format ?
res.json(JSON_OBJECT) Sends the JSON_OBJECT as the response to client
It depends on what are you doing. If we talk about fetch and a case with fetch(url).then(res => res.json()) it means parsing a json as a string to JS object.
Обсуждают сегодня