Programmatically consume the WebExtensions Schema JSON files from Mozilla. Version 0.5.1, updated infrequently (last release February 2024). Ships TypeScript types. Defaults to latest stable schema, but can specify any tag from mozilla-unified. Schemas are cached locally. Differentiates from passive schema downloads by providing a simple programmatic API with namespace filtering.
npm install webextensions-schemaNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Basic usage: install, import default function, call with options, use raw/namespaces/tag methods.
If offline, provide a specific 'tag' option from the local .schemas directory.
Use the full tag string as seen on https://hg.mozilla.org/mozilla-unified/tags.
Always await the webExtensionsSchema() call before accessing methods.
Use a unique tag or clear the .schemas directory if issues arise.
Monitor the GitHub repo for updates; consider caching schema files in CI.
Use: import webExtensionsSchema from 'webextensions-schema';
Use a specific tag like 'FIREFOX_126_0b9_RELEASE' or omit options for latest stable.
Ensure network access or use a tag that ships with the package (check .schemas directory).
Ensure to await the async call: const schema = await webExtensionsSchema();
No dependency data recorded yet.