Closed nikolay-yankov closed 8 months ago
I added support for MV3 only recently so it's possible that it's incomplete, but there is a test extension in the repo and it worked fine there. Make sure you have the required setup in the manifest.
Use v5, it's been published as a "next" version under a new name. I forgot to publish it completely.
npm install webext-permission-toggle@next
Thanks for you reply! I just tried the v5 from the standalone link but webextPermissions
is undefined. I'm using it by invoking addPermissionToggle({ reloadOnSuccess: true, });
Otherwise with the v4.1.0
it was set up properly (permissions, etc). The feature was working as intended for sometime and then ceases operation with that error.
Ok, I figured it out. It was because of my code in the extension. I had chrome.contextMenus.removeAll();
and completely forgot about it. I used it for other context menu items.
I'll continue with the v4.1.0
Sorry for the trouble.
After installing the chrome extension and after a few minutes I get the following error in the service worker:
Unchecked runtime.lastError: Cannot find menu item with id webext-domain-permission-toggle:add-permission
Then the buttonEnable ${manifest.name} on this domain
disappears from the context menu (right click the extension icon). I'm trying to debug in the library, but so far I don't have success. This happens in the latest version4.1.0
. The extension is running on Manifest v3.Any suggestions how to fix it are welcome. Thanks!