Skip to content

Function: humanizeLabel()

humanizeLabel(value, options?): string

Turn a raw statement column name into a human-readable header by tokenizing it (camelCase / snake_case / kebab / etc. all split) and Title-Casing each token: total_revenue -> “Total Revenue”, aiScore -> “AI Score” (the tokenizer special-cases ai). Falls back to the original string when tokenization yields nothing (e.g. a punctuation-only column name). The raw name is still used as the column id, accessor key, and CSV header, so only the on-screen label is prettified.

string

TokenizeOptions

string