Skip to main content

render_as_content_for

Function render_as_content_for 

Source
pub fn render_as_content_for(
    value: &ValueWord,
    _adapter: &str,
    _caps: &RendererCapabilities,
) -> ContentNode
Expand description

Render a ValueWord value as a ContentNode with adapter-specific dispatch.

Dispatch order:

  1. ContentFor → adapter-specific rendering (future: user-defined impls)
  2. Content → generic content rendering via render_as_content
  3. Display fallback → plain text

The caps parameter provides renderer capabilities so the Content impl can adapt output (e.g., use ANSI codes only when caps.ansi is true).