Posts

Post not yet marked as solved
2 Replies
682 Views
Hi. For my Safari Web Extension, using getMatchedRules() from declarativeNetRequest does not seem to work. I've declared the permission for declarativeNetRequestFeedback in my manifest.json file and tried the activeTab permission too. getMatchedRules() was added in a previous Safari release and was adjusted in Safari 16.4. I'm using Safari 16.5. It only returns an empty array when it's called. I know the rules are there and they're being applied from the static rules json, it's just that getMatchedRules() is not showing them for some reason. I'm using: const rules = await browser.declarativeNetRequest.getMatchedRules(); But it only ever returns: {rulesMatchedInfo: []} Can anyone tell me what I'm doing wrong please? The same code works fine in Chromium based browsers. Thank you.
Posted
by bgpost.
Last updated
.
Post not yet marked as solved
0 Replies
448 Views
Hi. I've made a Web Extension and my extension inserts CSS from the background service worker, I've declared the appropriate permissions in the Manifest.json file but I seem to be encountering an issue where it still needs to ask for permission from the user when they go to a page. Having them look for a yellow dot on the extension icon after it's already activated isn't very user friendly, people will miss this Is there a way to have the extension get permission from the user with a popup to begin when first activating the extension? I believe this is the way it's done for App Extensions. It would be nice to be able to just let them know about the permissions please ahead of time when the extension is activated. Thanks.
Posted
by bgpost.
Last updated
.