A Rust crate for building beautiful, declarative terminal user interfaces (TUIs), CLIs, and text-based IO with React-like syntax.
iocraft is a Rust crate for building beautiful terminal user interfaces (TUIs), command-line interfaces (CLIs), and text-based IO. It provides a declarative, React-like API that allows developers to create complex layouts, interactive elements, and fullscreen terminal applications with ease. The library solves the problem of building maintainable and visually appealing text-based interfaces in Rust.
Rust developers building terminal applications, CLI tools, or text-based interfaces who want a modern, declarative approach to UI development. It's particularly useful for those familiar with React or SwiftUI looking for similar ergonomics in Rust.
Developers choose iocraft for its clean, highly readable syntax and powerful features like flexbox layouts, hooks, and custom components. Unlike more imperative TUI libraries, it offers a declarative paradigm that reduces boilerplate and improves maintainability while supporting both interactive and static terminal output.
A Rust crate for beautiful, artisanally crafted CLIs, TUIs, and text-based IO.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Uses an element! macro inspired by React/SwiftUI, making UI code highly readable and reducing boilerplate, as shown in the clean hello-world example.
Integrates the taffy crate for CSS-like flexbox layouts, enabling complex and responsive UI designs such as tables and forms demonstrated in the examples.
Ensures consistent terminal output on both Unix and Windows systems, handling color and styling differences automatically per the README's broad support claim.
Supports dynamic behavior with hooks like use_state and use_future, allowing for state management and async operations, as seen in the counter example with animated updates.
Core functionality and examples depend on the smol async runtime, which may not align with projects using tokio or preferring synchronous code, adding unnecessary complexity.
Compared to mature alternatives like Ratatui, iocraft has fewer community resources, pre-built components, and may have less stable APIs, as hinted by its inspiration shoutouts.
Heavy reliance on procedural macros for element! and #[component] syntax can obscure compile errors and increase learning curve, especially for Rust beginners.