Code

Monospace code block for CLI commands, API identifiers, and short config samples.

Pass text for plain content. Pass inner_html only when you control the markup (for example pre-highlighted output from a trusted highlighter) — do not pass unsanitized user input to inner_html.

  • Single-line or multi-line code snippets in docs and settings panels - Inline monospace copy inside prose (wrap in a short text value)
Code snippet

A plain code block with a distinct code surface color from the theme.

cargo leptos watch
Multi-line block

Multi-line plain text for shell commands or config samples.

cargo leptos build --release
cargo leptos serve