24 releases (6 breaking)

9.3.2 Apr 29, 2024
0.7.0 Dec 2, 2024
0.6.4 Oct 22, 2024
0.6.1 Jul 24, 2024
0.2.2 Mar 28, 2024

#933 in Command-line interface

Download history 21/week @ 2024-08-19 15/week @ 2024-08-26 163/week @ 2024-09-02 6/week @ 2024-09-09 28/week @ 2024-09-16 68/week @ 2024-09-23 514/week @ 2024-09-30 397/week @ 2024-10-07 219/week @ 2024-10-14 193/week @ 2024-10-21 22/week @ 2024-10-28 63/week @ 2024-11-04 17/week @ 2024-11-11 26/week @ 2024-11-18 159/week @ 2024-11-25 230/week @ 2024-12-02

434 downloads per month
Used in 3 crates

MIT/Apache

60KB
1K SLoC

Bevy_ratatui

An experiment using Ratatui from within a Bevy app. Note that this library is explicitly unstable and will break compatibility between 0.x versions.

The goal of this (at least to start) is not to do any rendering / 3D / etc. in the terminal, but just to see how useful it is to use the bevy concepts for apps. This may change over time.

Example app

This app demonstrates:

  • Using the RatatuiContext resource to draw widgets to the terminal
  • ScheduleRunnerPlugin to run the app loop
  • Using Events to communicate
  • Handling States to add logic that runs on transition (e.g. changing the background color when going from Negative to Positive in a simple counter app)
cargo run --example demo

Keys:

  • Left / Right - modify the counter (look at what happens when you go negative)
  • Q / Esc - quit
  • P - simulate a panic (tests the color_eyre panic hooks)

Made with VHS

Compatible Bevy versions

bevy bevy_ratatui
0.15 0.7
0.14 0.6
0.13 0.5

Ideas on progressing this

Previous bevy_ratatui crate

Previously there was another crate using this name which has since migrated to ratatui_egui_wasm. A ratatui backend that is also an egui widget. Deploy on web with WASM or ship natively with bevy, macroquad, or eframe. Demo at https://gold-silver-copper.github.io/

License

Copyright (c) Josh McKinney

This project is licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

See CONTRIBUTING.md.

Dependencies

~30–44MB
~729K SLoC