![User banner](https://media.karab.in/55/48/5548ad6647aaa03b64d473cd2df25da07b22b9094ada12ccde1d628c76a3c793.webp)
![look997](https://media.karab.in/be/a3/bea34607fa012c9e3bdf63c21f5d2f2b364e78d7212e809124fe920d48be7fc1.webp?format=webp&thumbnail=64)
Przemyślenia, kwestie społeczne, polityka, śmieszki, anegdoty. Również technologia, webDev, AI, nauka.
Does the synchronization work on a zip file loaded from Add-ons -> Tools for all add-ons -> Install add-on from file...?
I do a basic browser.local.sync
sync test:
``` let monster = { name: "Kraken", tentacles: true, eyeCount: 10, };
let kitten = { name: "Moggy", tentacles: false, eyeCount: 2, };
browser.storage.sync.set({ kitten, monster });
```
and on the second profile:
``` await browser.storage.local.get("kitten");
```
but nothing happens, get("kitten")
returns nothing.
QUESTIONS:
- Does the synchronization work on a zip file loaded from Add-ons -\> Tools for all add-ons -\> Install add-on from file...?
I have in
manifest.json
applications.gecko.id
, as needed. - If not, what do I need to do to TEST the synchronization work?
API https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/storage/sync
Jak ja (pomagam w aborcji) nie cierpię płodów!!
Smerfastycznie.
@Kierunkowy74 Obrzydliwy to ten mastodon.social?
Funcions loadOneTab
and loadURI
in 2023 in Firefox Experimental API?
I am using the Experimental API in my private Firefox extension.
So far, I've been using Firefox 102 ESR, but I'm planning to switch to Firefox ESR 115. There's already a Firefox 115 Beta available, so I've started testing it with my private extension.
So far, I've been using internal Firefox functions like loadOneTab
and loadURI
and it worked very well.
I used the loadOneTab
function like this:
``` const placesURL = "chrome://browser/content/places/places.xhtml"; window.gBrowser.loadOneTab( placesURL, { inBackground: false, allowThirdPartyFixup : true, relatedToCurrent : true, triggeringPrincipal : services.scriptSecurityManager.getSystemPrincipal() } );
```
But the loadOneTab
function no longer exists at all in Firefox's internal API. What should I replace it with?
I found the function _createTab
:
``` // window.gBrowser._createTab({ uriString: placesURL });
```
But the _createTab
function returns an error:
``` Uncaught Error: UserInteraction with id "browser.tabs.opening" was not initialized
```
...I guess this is by security to make this function called only by user action? And I call this function inside async function
.
Is it somehow possible to open a new tab from the Experimental API in Firefox 115 beta? I need this very badly. Really very much.
---
I used the loadURI
function like this:
``` window.gBrowser.selectedBrowser.loadURI(linkGo, {triggeringPrincipal: Services.scriptSecurityManager.getSystemPrincipal()});
```
The loadURI
function appears to still be available in Firefox's internal API, but returns an error like this:
``` TypeError: 'uri' member of CancelContentJSOptions is not an object. RemoteWebNavigation.sys.mjs:28:41
```
How to overcome this error?
I'm wholeheartedly in favor of it, and I think ernest is also in favor of it, because I asked him. A matter of time.