From bf8237c4eda77f5dbeca1128003045c4211451bb Mon Sep 17 00:00:00 2001 From: Richard Bloor Date: Sat, 15 Mar 2025 05:32:19 +1300 Subject: [PATCH 1/2] Safari presidence for background pages and scripts --- .../add-ons/webextensions/manifest.json/background/index.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md b/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md index 75763e534ca77d7..46b9e8741875e8b 100644 --- a/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md +++ b/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md @@ -186,8 +186,7 @@ Support for the `scripts`, `page`, and `service_worker` properties varies betwee - `background.service_worker` is not supported (see [Firefox bug 1573659](https://bugzil.la/1573659)). - supports `background.scripts` (or `background.page`) if `service_worker` is not specified or the service worker feature is disabled. Before Firefox 120, Firefox did not start the background page if `service_worker` was present (see [Firefox bug 1860304](https://bugzil.la/1860304)). From Firefox 121, the background page starts as expected, regardless of the presence of `service_worker`. - Safari: - - supports `background.service_worker`. - - supports `background.scripts` (or `background.page`) if `service_worker` is not specified. + - supports `background.scripts` (or `background.page`) and `background.service_worker`. If both are specified uses `background.scripts` (or `background.page`), unless `preferred_environment` is set to `service_worker`. To illustrate, this is an example of a cross-browser extension that supports `scripts` and `service_worker`. The example has this manifest.json file: From 8ac6f34186017d522685f15204a0fe3c5c237bbd Mon Sep 17 00:00:00 2001 From: Richard Bloor Date: Sat, 15 Mar 2025 05:34:41 +1300 Subject: [PATCH 2/2] Grammar fix --- .../add-ons/webextensions/manifest.json/background/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md b/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md index 46b9e8741875e8b..dde551d07de6cf7 100644 --- a/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md +++ b/files/en-us/mozilla/add-ons/webextensions/manifest.json/background/index.md @@ -186,7 +186,7 @@ Support for the `scripts`, `page`, and `service_worker` properties varies betwee - `background.service_worker` is not supported (see [Firefox bug 1573659](https://bugzil.la/1573659)). - supports `background.scripts` (or `background.page`) if `service_worker` is not specified or the service worker feature is disabled. Before Firefox 120, Firefox did not start the background page if `service_worker` was present (see [Firefox bug 1860304](https://bugzil.la/1860304)). From Firefox 121, the background page starts as expected, regardless of the presence of `service_worker`. - Safari: - - supports `background.scripts` (or `background.page`) and `background.service_worker`. If both are specified uses `background.scripts` (or `background.page`), unless `preferred_environment` is set to `service_worker`. + - supports `background.scripts` (or `background.page`) and `background.service_worker`. If both are specified, uses `background.scripts` (or `background.page`), unless `preferred_environment` is set to `service_worker`. To illustrate, this is an example of a cross-browser extension that supports `scripts` and `service_worker`. The example has this manifest.json file: