A high-performance TUI framework for Go.
go get github.com/vito/tuist@latest# interactive selector
$ go run github.com/vito/tuist/demos@latest
# or run one directly
$ go run github.com/vito/tuist/demos@latest keygen # mandelbrot fractal, inline editors
$ go run github.com/vito/tuist/demos@latest grid # mouse hover/click grid, keyboard nav
$ go run github.com/vito/tuist/demos@latest logs # scrollback stress test, overlays, spinner- Everything is a component, embedding
tui.Compo - Components have lifecycle hooks (
OnMount,OnDismount) - Components can be hovered and focused (
SetHovered,SetFocused) - Components are fully interactive (
HandleKeyPress,HandlePaste,HandleMouse) - Components render to lines of text and can optionally control the cursor position
- Component renders are cached, and only re-render when
Compo.Updateis called - Output is diffed against previous frame and only changed lines are repainted
- If content changes off-screen, a full (synchronized) repaint is required (trade-off)
- Go-app - component system, lifecycle hooks, UI goroutine model
- pi-tui - the approach for repaintable scrollback; this project started as a straight-up conversion.
- BubbleZone - for the mouse region markers trick
- Bubbletea - a great TUI framework, I just needed a different model. This project leverages various components from its ecosystem (Lipgloss, Ultraviolet).
Used LLMs heavily. It wrote the commits, I write the docs.