pub fn render_auto_with_spec<T: Serialize>(
template: &str,
data: &T,
theme: &Theme,
mode: OutputMode,
spec: Option<&FlatDataSpec>,
) -> Result<String, Error>Expand description
Auto-dispatches with granular control over structured output.
Similar to render_auto, but allows passing an optional FlatDataSpec.
This is particularly useful for controlling CSV output structure (columns, headers)
instead of relying on automatic JSON flattening.
ยงArguments
template- A minijinja template stringdata- Any serializable data to render or serializetheme- Theme definitions for thestylefiltermode- Output mode determining the output formatspec- OptionalFlatDataSpecfor defining CSV/Table structure