Skip to content

v0.14.0: Full Deno and Bun Runtime Support

Choose a tag to compare

@Zheruel Zheruel released this 21 Sep 12:12
· 37 commits to main since this release

πŸš€ Full Deno and Bun Runtime Support

nano-string-utils now works seamlessly across all modern JavaScript runtimes: Node.js, Deno, and Bun!

✨ Highlights

  • πŸ¦• Deno Support: All 41 utility functions and CLI tool work natively in Deno
  • 🍞 Bun Support: Full compatibility with Bun runtime including performance optimizations
  • πŸ”§ Universal CLI: The nano-string CLI tool now runs in any runtime
  • βœ… Zero Breaking Changes: Existing Node.js users are unaffected
  • πŸ“¦ Zero Dependencies: Maintains our commitment to zero runtime dependencies

🎯 What's New

Runtime Abstraction Layer

  • Unified interface for cross-runtime compatibility
  • Automatic runtime detection (Node.js, Deno, or Bun)
  • Seamless stdin handling and path resolution across runtimes

Enhanced CLI Tool

  • Works with deno run, bun run, and Node.js execution
  • Full pipe support in all runtimes
  • Consistent behavior across all environments

Comprehensive Testing

  • Dedicated runtime compatibility tests for Deno and Bun
  • All 41 functions verified across runtimes
  • CI/CD pipeline extended with runtime compatibility checks

πŸ“– Usage Examples

Deno:
```typescript
// Import from JSR
import { slugify } from "jsr:@zheruel/nano-string-utils";

// Or use the CLI
deno run --allow-read https://unpkg.com/nano-string-utils/bin/nano-string.js slugify "Hello Deno"
```

Bun:
```bash

Install and use

bun add nano-string-utils

Use the CLI

bunx nano-string-utils camelCase "hello-bun-world"
```

Node.js:
```bash

Works as always

npx nano-string-utils kebabCase "HelloWorld"
```

πŸ“Š Runtime Compatibility Matrix

Runtime Library CLI Installation
Node.js β‰₯18 βœ… βœ… `npm install nano-string-utils`
Deno βœ… βœ… `deno add @zheruel/nano-string-utils`
Bun βœ… βœ… `bun add nano-string-utils`

πŸ“¦ Installation

NPM: `npm install [email protected]`
JSR: `deno add @zheruel/[email protected]`
Bun: `bun add [email protected]`

πŸ“š Documentation

Full documentation and interactive playground: https://zheruel.github.io/nano-string-utils/


Full Changelog: https://github.com/Zheruel/nano-string-utils/blob/main/CHANGELOG.md#0140---2025-09-21