Real browser extensions, built with every Extension.js release before it ships.
This repository holds 532 extension samples from ten upstream sources and the harness that builds them. A run takes one exact Extension.js version from npm, builds every buildable sample on Chrome, Firefox, Edge and Safari, and answers CLEAN or NOT CLEAN.
✅ CLEAN · 4.1.39
Framework health: 240/240 buildable samples pass (100.0%) · 4 skipped (sample-side/upstream)
Extension.js · Templates · Documentation · Release process
| Folder | Source | Samples |
|---|---|---|
chrome/ |
GoogleChrome/chrome-extensions-samples, plus retired MV2 samples under _archive/ |
302 |
chromium/ |
Chromium test extensions, a frozen subset that includes broken manifests on purpose | 87 |
mdn/ |
mdn/webextensions-examples | 71 |
extension.js/ |
Extension.js first-party examples | 60 |
wpt/ |
web-platform-tests/wpt, the test extensions under web-extensions/resources/ |
6 |
webextension-demos/ |
dotproto/webextension-demos | 2 |
vimium/ |
philc/vimium, report-only | 1 |
privacy-badger/ |
EFForg/privacybadger, report-only | 1 |
keepassxc-browser/ |
keepassxreboot/keepassxc-browser, report-only | 1 |
multi-account-containers/ |
mozilla/multi-account-containers, report-only | 1 |
Each folder is a copy of its source at one pinned commit. VENDORED.json in the folder records the source repository, that commit and a hash of the tree. Every run recomputes the hash, so a sample edited by hand fails the run.
Of the 532 samples, 248 are in the build matrix. The rest are kept as data: archived samples and manifests that are invalid by design. Four of the 248 are the report-only extensions described below. Four more cannot build for reasons of their own, such as a manifest that points at output the sample's own bundler must produce first. They are listed in skips.json with the reason and the date each was last verified. That leaves 240 buildable samples, and a failure in any of them is an Extension.js defect.
Eight sources are real extensions that a run builds and only reports. Their result is printed under the verdict and never changes it. A report-only sample that fails is a finding to read, with its report under bug-reports/ when the cause is Extension.js.
- Four load from source with no build step and are small enough to vendor, so every run builds them, the release gate included: Vimium, Privacy Badger, KeePassXC-Browser and Firefox Multi-Account Containers.
- The release builds of uBlock Origin Lite are about 65 MB and are not vendored, so only Weekly QA builds them.
- Three need their own build first, because the manifest in their repository is a template or names files only their bundler writes: Dark Reader, Obsidian Web Clipper and Refined GitHub. They have their own lane, described under Built extensions.
| Google Chrome ✅ Every release |
Microsoft Edge ✅ Every release |
Mozilla Firefox ✅ Every release |
Apple Safari ✅ Every release |
Every sample is built once per browser. Safari builds go through the converter and Xcode on a macOS runner, and nothing opens Safari: the corpus proves the build, not the run.
- The vendored folders match their recorded hashes.
- Each sample builds in its own throwaway workspace, once per browser.
- Every file the emitted
manifest.jsonnames exists in the output. A build that exits 0 and drops an icon is a failure. - The result is compared with
baseline.json, orbaseline.safari.jsonon macOS, the last accepted run of a stable version. A failing sample is built again before it counts, so a flaky runner is not reported as a regression.
A build that passes can still warn. The run log ends with the warnings of the passing cells: one that reads the same in several cells is printed once with its cell count and one cell to look at, and one that a single cell has is printed under that cell. The matrix report records warningsCount for each cell, null when the CLI under test wrote no build summary. A warning never changes a verdict.
| Workflow | Scope | Effect |
|---|---|---|
| Corpus gate | All 240 samples on Chrome, Firefox, Edge and Safari, at the commit the release pins, plus the four vendored report-only extensions | A stable Extension.js release does not publish unless the canary built from the same commit is CLEAN. Every release is then read again with the exact version that reached npm |
| Weekly QA | All samples at the latest upstream commits, against extension@latest, with Safari on a macOS lane |
Opens an issue for a regression that survives a second build |
| Built extensions | Three real extensions, each built by its own build command at a pinned commit, then built by Extension.js on Chrome, Firefox and Edge | Reports only. The job cannot fail the run and the gate does not call it |
| Smoke | 12 samples on Chrome and Firefox, on every push and pull request | Guards the harness itself |
Run the gate by hand for any version on npm:
gh workflow run corpus-gate.yml --repo extension-js/corpus -f cli-version=4.1.40-canary.458.001a6a0 -f safari=truenpm run smoke # 12 vendored samples, a few minutes
npm run qa # sync upstream, discover, build everything, report, verdict
npm run status # print the last verdict| Setting | CLI under test |
|---|---|
| (default) | extension@latest |
EXTENSION_TAG=4.1.40-canary.458.001a6a0 |
That exact version or dist-tag from npm |
EXTENSION_CLI_PATH=/abs/path/cli.cjs |
A local, unreleased build |
Scope a run with node scripts/run-matrix.mjs --source mdn --browsers chrome,firefox --limit 20. Safari builds through Xcode and runs on macOS only.
Some extensions cannot be built from their repository, because the manifest there is a template or names files that only the project's bundler writes. scripts/build-sources.mjs builds those first and hands the output to the same matrix:
- It fetches the one commit the source pins in
sources.json, a full SHA, never a branch. - It refuses a lockfile that resolves anything outside the npm registry, such as a git URL.
- It runs
npm ci --ignore-scripts, so no dependency runs code at install. - It runs the project's own build command, untouched, inside the clone, with an environment that holds no token.
- Each output folder named in
scanbecomes a sample, andextension buildbuilds it once per browser.
npm run built # fetch, install, build, then the matrix and the verdictThe project's source is never edited and its output is never committed: the clone lives in .cache/, which git ignores. These sources are always report-only. A project that fails to install or build is written to reports/builds.json and shows up as one failing report-only sample, and the verdict does not move.
To add one, add an entry with commit, build.run and the output folders in scan. Read the license at that commit first, and build it once from a clean clone. A project with a pnpm or Yarn lockfile is refused today: the registry check reads package-lock.json only.
Read catalog.json instead of searching for manifest.json. It lists every sample with its folder, manifest path, manifest version, API namespace (chrome.* or browser.*), entry points and whether it has a build step.
A refresh is a reviewed commit, never automatic.
npm run qa # build the latest upstream commits
npm run status # must be CLEAN
npm run vendor # copy the validated snapshot into the tracked folders
npm run discover:vendored # regenerate catalog.json
npm run baseline:update # accept the run as the new baselineTo add a source, add one entry to sources.json with its repository, the folders to scan and the tracked folder to vendor into. No code changes are needed. Check the license first: a source joins only when its license allows a redistributed copy, and the entry records the SPDX id. Set sparse: true for a repository far larger than its samples, submodules: true for one that keeps part of the extension in a submodule, and gate: false for a source that is reported and never decides the verdict. A real extension joins as report-only, and a source over 20 MB is not vendored. node scripts/sync.mjs --source <id> fetches one source and leaves the other pins alone.
MIT for the harness. The vendored samples keep the license of their source.