oven-sh/bun

Incredibly fast JavaScript runtime, bundler, test runner, and package manager – all in one

View on GitHub ↗Jump to charts ↓Open shareable report

Summary Information

Updated 24 minutes ago
Added to GitGenius on January 8th, 2023
Created on April 14th, 2021
Open Issues & Pull Requests: 8,439 (+1)
Number of forks: 4,996
Total Stargazers: 95,653 (+2)
Total Subscribers: 628 (+0)

Repository Insights (GitGenius)

How this project is maintained

Around half of the issues opened in the past year never receive a reply. 96% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. 57% of tracked open issues have had no activity in three months. Only 5% of issues opened in the past year have been closed. Three people close 61% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 3,330
New in 7 days: 202
Closed in 7 days: 98
Avg open age: 416 days
Stale 30+ days: 2,318
Stale 90+ days: 2,017

Recent activity

Opened in 7 days: 191
Closed in 7 days: 90
Comments in 7 days: 266
Events in 7 days: 748

Top labels

  • bug (8,646)
  • crash (3,374)
  • needs triage (2,735)
  • enhancement (1,911)
  • windows (1,511)
  • bun install (1,409)
  • runtime (1,319)
  • node.js (836)

Detailed Description

Bun is an all-in-one toolkit for JavaScript and TypeScript development, distributed as a single executable written in Rust and powered by JavaScriptCore. It functions as a drop-in replacement for Node.js while consolidating multiple development tools into one unified command-line interface. The runtime is designed to dramatically reduce startup times and memory usage compared to traditional Node.js environments, making it particularly suited for performance-critical applications.

The toolkit encompasses four primary components. The Bun runtime serves as the core JavaScript execution engine with Node.js compatibility. The bundler, accessible through the Bun.build API, handles module bundling with support for loaders, plugins, macros, CSS processing, HTML static site generation, hot module replacement, and bytecode caching. The test runner, invoked via bun test, provides testing capabilities including lifecycle hooks, mocking, snapshots, DOM testing, and code coverage reporting. The package manager replaces npm with commands like bun install, bun add, and bun remove, while also supporting workspaces, catalogs, and security scanning through a dedicated API.

Beyond these core tools, Bun provides an extensive runtime API surface. This includes HTTP server functionality through Bun.serve with routing and WebSocket support, binary data handling, streams, file I/O via Bun.file, and database connectivity through built-in SQLite, PostgreSQL, and Redis clients. Additional capabilities encompass S3 client integration, TCP and UDP socket networking, child process spawning, cron job scheduling, WebView support, FFI for foreign function interfaces, and a C compiler. The runtime also includes utilities for YAML, TOML, JSON5, JSONL, and Markdown processing, image processing, HTML rewriting, cookie and CSRF handling, and semantic versioning utilities.

The codebase shares contributors with major projects including Microsoft's VSCode and TypeScript repositories, as well as Remotion, suggesting cross-pollination with the broader JavaScript ecosystem.

Bun supports Linux on x64 and ARM64 architectures, macOS on both Intel and Apple Silicon, and Windows on x64 and ARM64. The project maintains canary builds on every commit to the main branch alongside stable releases. The comprehensive documentation covers installation, quickstart guides, TypeScript support including TypeScript 6, templating through bun init and bun create, and detailed API references for all runtime features. Deployment guides address major cloud platforms including Vercel, Railway, Render, AWS Lambda, DigitalOcean, and Google Cloud Run.