mustache-bun
v4.2.2
Published
High-performance, Bun-native refactor of mustache.js. Purged legacy bloat, optimized for raw string rendering with zero-overhead.
Maintainers
Readme
Mustache-Bun
mustache.js - Logic-less {{mustache}} templates with JavaScript
A high-performance, bulk refactor of the legendary mustache.js, re-engineered specifically for the Bun runtime.
Stop carrying the weight of 2015. mustache-bun is a stripped-down, pure ESM version that purges a decade of legacy bloat to deliver the fastest string templating experience on Bun.
Why this refactor?
- Bun-Native & Node-Free: Completely removed the UMD wrapper and legacy Node.js dependencies. No
ws, nohttp, no emulated layers. - High-Speed Raw Rendering: Optimized for speed by removing HTML escaping overhead. It serves your data raw, exactly as you need it for high-frequency tasks like Discord transcripts.
- Zero-Dependency Supply Chain: Purgated 300MB+ of
devDependencies(Puppeteer, Mocha, etc.) from the source. The repo is now clean, safe, and lightning-fast to install.
📦 Bundle Size Comparison
| Package | Unpacked Size | Dependencies | Total Install | | :--- | :--- | :--- | :--- | | mustache (official) | ~114 kB | Legacy Bloat | ~114 kB | | mustache-bun (yours) | ~24.1 kB | NONE | ~24.1 kB |
~79% smaller than the original!
Installation
bun add mustache-bunDocumentation & Credits
Original logic and architecture by Jan Lehnardt (janl). For full usage instructions, refer to the official documentation. Refactored, optimized, and maintained for the Bun ecosystem by Luigi Colantuono.
