Skip to main content

render_bordered

Function render_bordered 

Source
pub fn render_bordered(
    headers: &[impl AsRef<str>],
    rows: &[Vec<impl AsRef<str>>],
) -> String
Expand description

Render a dynamic-column table with ASCII borders and left-aligned cells.

All cells are terminal-escaped before measuring the same Unicode scalar columns as render. Missing cells are empty; extra cells create unnamed columns. No columns returns empty text. Header-only output retains its separator. The result has no final newline and preserves cell whitespace. Callers own value semantics, row construction, input/output budgets and all terminal/output policy. Allocation follows ordinary String/Vec semantics.