We currently have an extension in the Chrome Web Store with many users. We currently request access to foo.site.com but now we'd like to update our permissions so that we can get bar.site.com.
As I understand it now, if we push a new update (new extension version to the Chrome Web Store) requiring these two permissions, existing users will have their extension disabled until they manually re-enable. New users who download the extension after the update will be fine and have both permissions. However, disabling our current users is not an option.
Any way to get around this?
We've looked into optional permissions, which would solve the issue for existing users (we would just ask them to click a button to upgrade the permissions and be on our way). However for new users, they would not only have to install the extension but also accept the optional permissions which sucks. Is there any way for new users to accept all the permission (optional and required) at install time?
Yes, there is solution. You set the new permissions as optional, and then you request the permission before the user using the new feature. The is work 100%.
This is what you add to your manifest:
"permissions": ["tabs","http://*/*","https://*/*"],
After that you can use:
chrome.permissions.request
and
chrome.permissions.contains