flat_file_renderers.text module

flat_file_renderers.text.replace_crlf(val: str) → str[source]

Replaces embedded newline/carriage-return characters with a visible \n/\r marker.

Useful before writing a value into a single tabular cell (CSV/TSV/XLSX/HTML), where a raw embedded line break would otherwise corrupt the row layout.