Running examples

The Book

Use the cargo run --bin command to list possible examples, and run them.

We do this because it allows us to have different dependencies between examples.

Specific example docs


The most minimal code to show usage of cuicui_layout using cuicui_dsl


A single menu made using cuicui_dsl.


A single menu supporting hot reloading made using cuicui_chirp.


Library of plugins useful for the more advanced examples.

  • SwitchPlugin: An event-driven toggle between N children of an entity
  • MirrorPlugin: A way to sync Reflect components with non-Reflect 3rd party components.
  • HighlightPlugin: bevy_mod_picking-based hover highlight that tries to be smart about color changes.


A tabed menu with three different screens


A clone of the cyberpunk 2077 main menu and settings menu.

Demonstrates full end-to-end usage of .chirp, including common patterns for managining complexity.

This example requires additional steps to work properly.

Check the example’s README for more details.


Demonstrates the equivalence between the dsl! macro and the .chirp file format. Also used as a test to make sure it is trully equivalent.


Demonstrates usage of cuicui_layout_bevy_sprite. Due to a quirk in the way cargo resolves workspace features, the debug overlay is specifically broken for this. You need to use the following command line to run it with the layout debug overlay:

cargo run --bin sprite_debug -p sprite_debug --features cuicui_layout/debug


demonstrates usage of the cuicui_chirp templating features. See the file in assts/templates.chirp for details, as most of the interesting code is in the chirp file itself, not the rust source code.