How can I listen to all requests?
I am trying to create an extension that will intercept all requests that were made on the webpage. How can I do this?
4 Replies
A content script will be injected to each webpage from your extension, but this is general. It will be injected to every page, and you can intercept requests by overriding the fetch function if you really need to. What is it for exactly?
@Yintii has reached level 2. GG!
Actually, it would process on the server first before getting to the client no matter what, so you’d need a proxy server that your plugin uses between the actual server most likely
you can use
chrome.webRequest
api to listen for a variety of network-related events