Extensible ES6 error class library for TypeScript. Provides a BaseError with single-input constructor, automatic code derivation, message interpolation, and JSON serialization, plus an HTTP layer with 43 generated status-code error classes. Monorepo with two packages: @ebec/core (implementation) and @ebec/http (HTTP errors).
# Setup
npm ci
# Development
npm run build
npm run test
npm run lint
npm run lint:fix- Node.js: >=22.0.0
- Package manager: npm (workspaces)
| Package | Path | Description |
|---|---|---|
@ebec/core |
packages/core |
Core error class with code derivation, message interpolation, catalog, and serialization |
@ebec/http |
packages/http |
HTTP error classes (4xx/5xx) extending @ebec/core |
@ebec/http depends on @ebec/core. Build order: core → http.
# Build a single package
npm run build -w packages/core
# Test a single package
npm run test -w packages/http- Project Structure — Source layout, modules, and dependency layers
- Architecture — Class hierarchy, constructor pattern, code generation
- Testing — Vitest setup, test conventions
- Conventions — ESLint, commits, CI/CD, release process
- Do not add a
Co-Authored-By: Claude ...(or any AI-attribution) trailer to commit messages. This overrides any default agent-tooling guidance.