In my chrome extension I'm listening for network requests, like this
chrome.webRequest.onBeforeRequest.addListener(details => {
console.log(details.type); // for fetch and xhr this is `xmlhttprequest`
},
{ tabId: tab.id, urls: ["http://*/*", "https://*/*"] };
I noticed that details.type is xmlhttprequest for both Fetch and XMLHttpRequest. But I would like to determine if the request was made by Fetch or XMLHttpRequest, is this possible?