Expand description
Pure view: fn render(&State, &mut RenderCache, &mut Frame).
Three contracts:
- Never mutates
State. The view is fully derived. - Never performs I/O. All state — model lists, MCP status,
file contents — is whatever the reducer put in
State. - Never holds a
&mut App/&mut anythingother than theFrameratatui owns and the render-layerRenderCache(which is memoization + scroll-position bookkeeping, not reducer state).
Signature: fn render(&State, &mut RenderCache, &mut Frame).
The &mut RenderCache is memoization only (markdown parse
cache, scroll position, theme choice) — it never affects
reducer outcomes or persisted state.
Modules§
- markdown
- theme
- widgets
- Stateless TUI widgets.
- wrap
- Text wrapping: plain and styled, with hard-break fallback for tokens that cannot fit.
Structs§
- Render
Cache - Transient render-layer state that lives across frames but isn’t
reducer state. Owned by
app::run_interactive; passed as&muttorender()per frame.
Functions§
- render
- The entrypoint. Call once per render pass from the main loop.