In the browser, I'm doing an HTTP request. The resource at reqUrl doesn't enable CORS, so there's no response body. But how can I get the response header? (I can see it in the DevTools' network tab.)
var p = fetch(reqUrl, { method: "POST", headers: reqHeader, body: reqBody }); p.then(function () { }) .catch(function (err) { // CORS is disabled so I'm arriving here // "TypeError: NetworkError when attempting to fetch resource." });