You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: complete Phase 3 - error transformation and performance optimizations
## Error Transformation
- Add `map()` method to all matchers for error transformation before matching
- Support chaining transformations with method chaining
- Enable error normalization, nested error extraction, and context addition
- Works with both exhaustive and non-exhaustive matching
## Performance Optimizations
- Implement tag-based lookup tables using Map for O(1) error matching
- Fast-path matching for errors created with `defineError()` (have `tag` property)
- Fallback to instanceof checks for non-tagged errors
- Apply optimization to both sync and async matchers
- Significant performance improvement for large error unions
## Documentation
- Add comprehensive examples for `map()` transformation
- Document performance characteristics
- Update roadmap: Phase 3 completed (3/4 features, 1 deferred)
## Bundle Size
- Final size: 5.16 KB (minified)
- All tests passing: 57/57
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
0 commit comments