Thanks for your interest. Bug reports, fixes and proposals for the provider surface are welcome.
npm ci
npm test # tsc over index.js (checkJs) and test/consumer.ts against index.d.tsThere is no build step: index.d.ts and index.js are published as they are.
index.d.ts— the WebRGB provider surface (window.rgb), its error codes and thergb:readyevent.index.js—requestProvider(), the only runtime code.test/consumer.ts— a compile-only dApp. It pins what a consumer can write and, through@ts-expect-error, what it cannot. Extend it whenever you touch the declarations.
The declarations mirror the reference implementation in the KaleidoSwap
browser extension (src/injected.ts). Propose surface changes there first, or
alongside; a declaration for a method no wallet serves helps nobody.
- Adding a method or an optional field: minor version.
- Changing or removing a signature, an error code or an event: major version.
- Record every change in
CHANGELOG.mdunderUnreleased.
- Branch from
dev;maintracks upstream. - Keep
npm testgreen; CI runs it on Node 20 and 22 and then installs the packed tarball into a bare project to prove it imports. - Open a pull request with a short rationale. Link the extension change when there is one.
Maintainers: bump version in package.json, move the Unreleased notes under
a dated heading in CHANGELOG.md, commit, then
git tag v<version> && git push --tagsThe publish workflow waits for a reviewer on the npm environment, runs the
tests, checks the tag against package.json and publishes with provenance.
See SECURITY.md. Never open a public issue for a vulnerability.