What's the best way to keep API usages simple but working for both MV3 and MV2 (due to Firefox dev)? #1851
Unanswered
Destroy666x
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm new to browser extension development. The problem:
So e.g.
browser.action.setBadgeBackgroundColor
throws an error in Firefox because it wantsbrowser.browserAction.setBadgeBackgroundColor
. This makes the extension not easily testable on FF. I've seen the GH/FF issues regarding this and it'll likely take a while to have dev mode support FF MV3. I don't really want to do(browser.action ?? browser.browserAction)
kind of workarounds.What would be the best solution for it as of now? I've seen some polyfill got removed in recent major WXT version. Would installing it help? Would it introduce any issues? Or is there some other automated way that polyfills or does something to solve the MV3/MV2 testing incompatibilities?
Beta Was this translation helpful? Give feedback.
All reactions