When the request status is greater than 400(I have tried 400, 423, 429 states), fetch cannot read the returned json content. The following error is displayed in the browser cons
I know it's too late but it can help someone:
let response = await fetch(targetUrl); let data = await response.json();