BetterTUI
Open-source terminal UI framework pairing a 32,000-line Rust rendering engine with a type-safe TypeScript and React 19 API — 250+ downloads across npm and crates.io within 13 days of release.

The project
BetterTUI is a Rust-powered terminal UI framework exposed to JavaScript. The engine — bettertui_engine on crates.io, about 32,000 lines of Rust — also ships through npm as @bettertui/core with 8 prebuilt platform binaries, so apps install it without a Rust toolchain.
It lays out UI with Taffy flexbox and grid, renders through a framebuffer with dirty-region diffing that targets 60fps, edits text with ropes (undo/redo, search, selection), and highlights code with tree-sitter across 7 languages.
Above the engine sits a framework-agnostic TypeScript core with a React 19 adapter — useRuntime, useKeyboard, useFocus, useTheme, and useTimeline hooks — around 30 built-in widgets including chat and markdown components, VT emulation with a built-in PTY, tween/spring/keyframe animation, and in-core DevTools.
Within 13 days of the August 2026 release it passed 250 downloads across npm and crates.io. The monorepo ships 64 runnable examples and full docs at bettertui.dev. MIT licensed.
What I owned
Architect and author — designed the Rust rendering engine and the type-safe TypeScript API on top of it.
What I built
- 32,000-line Rust engine published to crates.io (
bettertui_engine) and npm (@bettertui/core) with 8 prebuilt platform binaries — no Rust toolchain needed to install - Framebuffer renderer with dirty-region diffing targeting 60fps, over an arena-allocated node tree with generational indices that avoids GC pauses
- Taffy-powered flexbox and grid layout; rope-based text editing with undo/redo, search, and selection
- Tree-sitter syntax highlighting for JavaScript, TypeScript, Rust, Python, JSON, HTML, CSS, and Bash
- Around 30 built-in widgets including chat components and markdown rendering, plus a NerdFont glyph registry
- React 19 adapter —
useRuntime,useKeyboard,useFocus,useTheme,useTimelinehooks — over a framework-agnostic core, with a SolidJS adapter planned - VT emulation with built-in PTY support, tween/spring/keyframe animation, and in-core DevTools with testing utilities
- 64 runnable examples, Vitest performance benchmarks, and docs at bettertui.dev — 250+ downloads across npm and crates.io in the first 13 days