Post

Replies

Boosts

Views

Activity

Reply to include_globs not supported for content_scripts
The use case here is to help collapse permissions. If you have these two content scripts: { 			"css": [ "style-a.css" ], 			"matches": [ "https://*.example.com/*" ], 			"include_globs": [ "https://a.example.com/*style=a*" ], 			"run_at": "document_start" }, { 			"css": [ "style-b.css" ], 			"matches": [ "https://*.example.com/*" ], 			"include_globs": [ "https://b.example.google.com/*style=b*" ], 			"run_at": "document_start" } The permissions for these content scripts would merge into *.example.com, and the permission would be a clean host permission.
Dec ’20
Reply to browser.storage.onChanged doesn't appear to work on Safari
I've been dealing with the same issue! As temporary solution, I had to fall back to polling the storage for safari: 	const isSafari = chrome.runtime.getURL('').startsWith('safari-web-extension://'); 	if (isSafari) { 		// browser.storage.onChanged.addListener 	} else { 		// setInterval browser.storage.sync.get 	} Yet this is no way to work with storage. Is there a better way to detect if this is supported or not? (especially once safari fixed the issue)
Dec ’20
Reply to Protocol source matches for CSP in extensions not supported
To allow developers to enforce a more strict CSP. Basically without wildmark matches I have to leave out the directive completely. For example, one use case is limiting the set of images an extension is able to load in their own context. Normally, any image can be loaded within the extension, yet when you set this as CSP: default-src: none; img-src: https:; Only images from https can be loaded. Feedback has been filed, #8968973
Jan ’21
Reply to Correct sizes and colours for toolbar icon
Would love to know this as well. Sadly SVG and theme_icons are currently only supported in Firefox. Changing the extension icon based on dark mode / on runtime could be done in the background page. Keep in mind there are browsers which can't handle the onChange listener for matchMedia, so don't rely on that. You can consider creating a feedback assist request: https://feedbackassistant.apple.com/ .
Jul ’21