I’m working on a browser extension that needs access to the “login” key from the “window” object of the active tab.
There is my manifeset.json
{...}
"permissions": [
"activeTab",
"storage",
"scripting",
"tabs"
],
"background": {
"service_worker": "background.js",
"type": "module"
},
"content_scripts": [
{
"matches": ["<all_urls>"],
"js": ["content.js"]
}
],
Additional I have popup.js
attached to popup.html
, and I need to have window.login
in that file.
Currently everytime when I tried to get access to window, there is a window before all react loaded so there is almost empty window. I used window.onload and it didn’t work,