mirror of
https://github.com/oven-sh/bun
synced 2026-02-13 12:29:07 +00:00
Implements Bun.ms as a drop-in replacement for the npm ms library.
Parses time strings like "2d", "1.5h", "5m" to milliseconds and formats
numbers back to human-readable time strings.
- Implemented in Zig for reusability with future bundler optimizations
- Supports all time units: ms, s, m, h, d, w, y with variations
- Case-insensitive parsing with whitespace handling
- Formats with short ("1m") and long ("1 minute") options
- Comprehensive test coverage with 226 runtime + 1 bundler test
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>