I have 2 different extensions, extensionA and extensionB
extensionA has a declarativeNetRequest rule with a regex filter of ^https://(.*).
example.com(.*)$ to add a header to every request.
If I were to drop the url '
https://domainA.example.com/path/to/page' directly into the address bar, the rule will take effect and the header will be added to the request.
However whenever I click the same url link
within extensionB, the rule doesn't take effect.
How do I modify the rule in extensionA to get the link within extensionB to follow the rule specified in extensionA
here is the rule in question:
{
action: {
type: "modifyHeaders",
requestHeaders: [{"header": "x-custom-header", "operation": "set", "value": "true"}]
},
condition: {
"regexFilter": "^https://(.*)\.example\.com(.*)$",
resourceTypes: [ "main_frame" ]
},
id: 1,
priority: 1
}