gfw.common.strings#

Small utilities for common string manipulation tasks.

This module provides lightweight helpers to transform and clean text for practical use across the codebase.

Functions

collapse_paragraphs

Collapse paragraphs with arbitrary newlines ('n') into single lines.

collapse_paragraphs(text)[source]#

Collapse paragraphs with arbitrary newlines (’n’) into single lines.

Return type:

str