Fix Firefox install: use background.scripts instead of service_worker
CI / Build & Test (push) Successful in 3m22s

Firefox MV3 does not support background.service_worker. Split background
into background-boot.js (globals) and background-main.js (startup logic);
Chrome keeps using importScripts() in background.js, Firefox manifest uses
background.scripts with the same file list so the extension loads in both.
This commit is contained in:
Raven Scott
2026-03-03 02:15:03 -05:00
parent 5fdafbcc33
commit 34303e7a80
6 changed files with 62 additions and 46 deletions
+10 -1
View File
@@ -29,7 +29,16 @@
}
},
"background": {
"service_worker": "background.js"
"scripts": [
"background/background-boot.js",
"background/logs.js",
"background/state.js",
"background/proxy.js",
"background/native-messaging.js",
"background/tab-lifecycle.js",
"background/message-router.js",
"background/background-main.js"
]
},
"content_scripts": [
{