I'm currently developing a Chrome Extension by my own. By far, I designed the front-end using the React App and it has no functionality yet. At this moment, I'm willing to add to a button an 'on click' functionality that will be able to act by the following steps:
Scan the window object (and window.document) of the current opened tab
Open a new temporary tab (at the same host, with no violation of Same-Origin policy), and there also scan the window object (and window.document) and then close this temporary tab.
Sending the relevant extracted data to a remote log server.
The problem that I'm currently faced with is that any script of the extension is running at the context of the extension itself, and not at the context of the currently opened tab. What I'm wondering is how can I slove this context issue (so the code will run where I expects it to run), and also what kind of permissions and other properties should I add to my manifest.json file?
Thanks in advance!