Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork488
A Rust crate for cooking up terminal user interfaces (TUIs) 👨🍳🐀https://ratatui.rs
License
ratatui/ratatui
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
Table of Contents
Ratatui Website ·Docs ·Widget Examples ·App Examples ·Changelog
Breaking Changes ·Contributing ·Report a bug ·Request a Feature
Ratatui (ˌræ.təˈtu.i) is a Rust crate for cooking up terminal user interfaces(TUIs). It provides a simple and flexible way to create text-based user interfaces in the terminal,which can be used for command-line applications, dashboards, and other interactive console programs.
Ratatui hastemplates available to help you get started quickly. You can use thecargo-generate command to create a new project with Ratatui:
cargo install --locked cargo-generatecargo generate ratatui/templates
Selecting the Hello World template produces the following application:
use color_eyre::Result;use crossterm::event::{self,Event};use ratatui::{DefaultTerminal,Frame};fnmain() ->Result<()>{ color_eyre::install()?;let terminal = ratatui::init();let result =run(terminal); ratatui::restore(); result}fnrun(mutterminal:DefaultTerminal) ->Result<()>{loop{ terminal.draw(render)?;ifmatches!(event::read()?,Event::Key(_)){breakOk(());}}}fnrender(frame:&mutFrame){ frame.render_widget("hello world", frame.area());}
- Docs - the full API documentation for the library on docs.rs.
- Ratatui Website - explains the library's concepts and provides step-by-step tutorials.
- Ratatui Forum - a place to ask questions and discuss the library.
- Widget Examples - a collection of examples that demonstrate how to use the library.
- App Examples - a collection of more complex examples that demonstrate how to build apps.
- ARCHITECTURE.md - explains the crate organization and modular workspace structure.
- Changelog - generated bygit-cliff utilizingConventional Commits.
- Breaking Changes - a list of breaking changes in the library.
You can also watch theEuroRust 2024 talk to learn about common concepts in Ratatui and what'spossible to build with it.
If you're looking to get started quickly, you can use one of the available templates from thetemplates repository usingcargo-generate:
cargo generate ratatui/templates
Check out theshowcase section of the website, or theawesome-ratatui repository for a curatedlist of awesome apps and libraries built with Ratatui!
Feel free to join ourDiscord server for discussions and questions!There is also aMatrix bridge available at#ratatui:matrix.org. We have also recently launched theRatatui Forum.
We rely on GitHub forbugs andfeature requests.
Please make sure you read thecontributing guidelines beforecreating a pullrequest. We accept AI generated code, but please read theAI Contributionsguidelines to ensure compliance.
If you'd like to show your support, you can add the Ratatui badge to your project's README:
[](https://ratatui.rs/)
Ratatui was forked from thetui-rs crate in 2023 in order to continue its development. None ofthis could be possible withoutFlorian Dehau who originally createdtui-rs which inspired manyRust TUIs.
Special thanks toPavel Fomchenkov for his work in designing an awesome logo for the Ratatuiproject and organization.
This project is licensed under theMIT License.
About
A Rust crate for cooking up terminal user interfaces (TUIs) 👨🍳🐀https://ratatui.rs
Topics
Resources
License
Code of conduct
Contributing
Security policy
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Sponsor this project
Uh oh!
There was an error while loading.Please reload this page.
