when using the fetch statement in JavaScript, like so:
fetch (url, data)
.then(response => response.json())
.then(data => {})
.catch ((error)=>{console.error ('Error: ',error)});
If an error occurs such as:
Error: SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data
Is there somehow to view the raw data that was received by the call and led to the parsing error, rather than just the error message?