Skip to content

Manifest V3

Ng Guoyou edited this page Jul 14, 2026 · 14 revisions

Manifest V3 architecture

Save In 4 uses one MV3 manifest and the same TypeScript entry module for Firefox and Chrome.

Requirements

  • Firefox 121 or newer
  • Chrome/Chromium 123 or newer

Firefox loads background.scripts as a non-persistent event page. Chrome loads background.service_worker. The staged store package points both entries at bundles built from the same source.

Service-worker rules

  1. Browser event listeners are registered synchronously at module startup.
  2. State required across wakeups is persisted in local or session storage.
  3. Shared code cannot assume a DOM, window, or URL.createObjectURL.
  4. Chrome filename decisions return true synchronously before resolving asynchronously.
  5. Content scripts tolerate a reloaded or temporarily unavailable extension context.

Permissions and network behavior

Save In requests host access so click-to-save, page inspection, and supported download operations can work on pages. Firefox users can revoke host access; the options page reports when required access is missing.

Save In requests declarativeNetRequestWithHostAccess for the optional Referer feature, but does not request webRequest or webRequestBlocking. Both browsers use a temporary session rule around each exact extension-owned metadata or content request and remove it afterward. Firefox can still attach the Referer natively to a direct final download; Chrome instead fetches the protected content and passes a local Blob to the downloads API.

Cross-origin file fetching happens in an extension context with host permission, not in the content script. The retired content-script fetch option is no longer part of the product.

See Authenticated downloads and request context for the differences between direct downloads and fetch-to-Blob downloads, including cookies, Referer, containers, and private browsing.

Build and reviewability

The TypeScript modules are bundled into one readable, non-minified file per execution target. Store builds and browser tests use the same staged bundle. No remotely hosted code is used.

See Firefox vs Chrome for user-visible capability differences.

Clone this wiki locally