Right now the `Addon:Install` command only supports a single flag which is for a temporary installation. It would be helpful to also have an eg. `allowPrivateBrowsing` flag which would set the right permissions to let the add-on also run in private browsing windows.
Therefore some additional permissions have to be set after the addon has been installed and it's `id` is known. This could look like:
+ const perms = {
+ permissions: ["internal:privateBrowsingAllowed"],
+ origins: [],
+ };
+ await lazy.ExtensionPermissions.add(id, perms);
+ let addon = await lazy.AddonManager.getAddonByID(id)
+ await addon.reload();
Bug 1810718 Comment 0 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
Right now the `Addon:Install` command only supports a single flag which is for a temporary installation. It would be helpful to also have an eg. `allowPrivateBrowsing` flag which would set the right permissions to let the add-on also run in private browsing windows.
Therefore some additional permissions have to be set after the addon has been installed and it's `id` is known. This could look like:
```
+ const perms = {
+ permissions: ["internal:privateBrowsingAllowed"],
+ origins: [],
+ };
+ await lazy.ExtensionPermissions.add(id, perms);
+ let addon = await lazy.AddonManager.getAddonByID(id)
+ await addon.reload();
```