Native Rendering Core
Layout, frame composition, and terminal output run in a Rust engine, while application code stays in TypeScript.
BetterTUI is an open-source framework for Node.js terminal applications. Write a typed interface in TypeScript while the engine handles layout, input, and terminal rendering natively.
import { Box, Text, createCliRenderer } from "@bettertui/core";
const renderer = await createCliRenderer({ exitOnCtrlC: true });
const app = new Box(renderer, {
flexDirection: "column", padding: 1,
});
app.add(new Text(renderer, { content: "Hello, terminal." }));
renderer.root.add(app);
renderer.start();Start with a clear next step
BetterTUI is being built in public. Whether you are evaluating it, trying it, or following its progress, the important paths are easy to find.
01 · Build
Follow the quick start, then move through the core concepts and component reference at your pace.
Open the quick start02 · Verify
Review the current measurements, the scenarios behind them, and the harness used to generate the results.
See the evidence03 · Support
Read the source, track the work, and leave a star if the project is worth following for you.
Visit the repositoryFeatures
BetterTUI keeps application code approachable while moving terminal-specific work into a dedicated native engine.
Layout, frame composition, and terminal output run in a Rust engine, while application code stays in TypeScript.
The project targets modern Node.js first, with a native addon and an API shaped for terminal applications rather than browser assumptions.
A command buffer, runtime, and tree reconciliation layer keep the engine independent from any one component model.
Rust ownership and generational node identifiers help protect native rendering work from whole classes of stale-reference mistakes.
Compose layout, text, input, scrolling, selection, and events from primitives designed for interactive terminal surfaces.
Typed commands, testing helpers, diagnostics, and public benchmarks make the work inspectable instead of asking you to trust a headline.
Core first
Start directly with the core when you want a clear view of the renderer, nodes, events, and update flow. Higher-level adapters can build on the same engine boundary.
import { Box, Text, createCliRenderer } from "@bettertui/core";
const renderer = await createCliRenderer({ exitOnCtrlC: true });
const panel = new Box(renderer, {
flexDirection: "column", padding: 1,
});
panel.add(new Text(renderer, {
content: "Ready to build.",
}));
renderer.root.add(panel);
renderer.start();Your application
State, layout intent, component composition, and interaction rules remain understandable TypeScript.
The engine
Layout calculation, frame composition, terminal output, and low-level input handling run behind a deliberate native boundary.
Designed for interaction
Combine layout, keyboard input, focus, and dynamic state into a terminal interface that has room to grow with the workflow behind it.
How It Works
Your application describes the interface. BetterTUI turns that intent into commands, then the native engine lays out and renders the terminal frame.
Your app
Application Layer
TypeScript application code · framework adapters can build on the same core
Layer 2
@bettertui/core
Command buffer · runtime · tree reconciliation
A typed TypeScript layer that batches UI updates and coordinates the boundary between your application and the native engine.
Layer 3
Rust Engine
Flexbox layout · ANSI renderer · terminal events
The hot render path stays native. Rust ownership and generational node identifiers help the engine reject stale references before they become rendering work.
Built in public
BetterTUI is a long-term investment in the tools people use every day. The project is shared early so the community can see, question, and improve the direction with it.
Why this exists
I am putting sustained time and care into BetterTUI because terminal applications deserve a thoughtful, dependable foundation. The goal is not to ship another demo; it is to make a project the community can inspect, shape, and eventually rely on.
A star, a question, a bug report, or an honest note about the workflow you need all make a real difference while the project is still taking shape.
BetterTUI is an early preview. The API will change, and it is not ready for production workloads yet. Clear limits are part of building trust.
The source, architecture notes, benchmarks, and development decisions are available to inspect. You can decide whether the direction earns your time.
The best terminal tooling comes from real workflows. Feedback, questions, and small experiments help turn a promising engine into a useful community project.
Early preview
See what is planned, then share the problem you would like BetterTUI to solve.
I am building BetterTUI in public, one careful decision at a time. A star on the repository is a small signal that helps other builders find the work and gives me real momentum to keep investing in it.
MIT licensed · You can also follow the roadmap or start with the quick start.