@revertwtf/catalog
v0.1.2
Published
Curated catalog of EVM, RPC, wallet, account abstraction, and protocol errors
Maintainers
Readme
@revertwtf/catalog
Curated catalog of EVM, RPC, wallet, account abstraction, and protocol errors.
pnpm add @revertwtf/cataloggetCatalog()- all entriesgetEntry(id)- single entrysearchCatalog(q)- string search across id/title/summary/category/source metadatagetEntriesByLayer(layer)/getEntriesByCategory(cat)getCatalogSourceMetadata(source)- source display name, aliases, lifecycle, notesgetBlockscoutChains()/getBlockscoutChain(chainId)- generated Blockscout registry snapshotsearchBlockscoutChains(q)/getBlockscoutChainStats()- Blockscout chain lookup helpersdescribePanic("0x11")- Solidity panic-code dictionary, also available as the tiny@revertwtf/catalog/panicsubpathnormalizePanicCode("0x000...0011")- canonicalizes valid0x-prefixed panic-code hex and rejects ambiguous values such as"17"
Entries are pure data in src/data/shards/. Source display names and lifecycle
labels live in src/sources.ts so raw source IDs stay stable.
@revertwtf/catalog is the full catalog surface. Browser apps that only need
small dictionaries or one shard should use explicit subpaths so they do not
bundle the full catalog data by accident.
Bundle-size guide
| Subpath | Approx size | Use when |
| --- | ---: | --- |
| @revertwtf/catalog/panic | < 2 KB | only need Solidity panic codes |
| @revertwtf/catalog/shards + loadShard("solidity") | ~10 KB for solidity, varies by shard | client or server app needs one shard |
| @revertwtf/catalog/data-full | very large raw JSON | server-side, need everything |
| @revertwtf/catalog | full catalog surface | server-side programmatic catalog access |
Blockscout chain coverage lives in src/data/blockscout-chains.json, generated
from Blockscout. Refresh it with pnpm catalog:update-blockscout, then run
pnpm catalog:build-data, pnpm validate:catalog, and
pnpm catalog:duplicates.
