linebreaks
Convert newlines into < p > and < br >s.
def linebreaks(
value: string,
autoescape: boolean = False
) - > string
Convert newlines into < p > and < br >s.
Parameters
| Name | Type | Description |
|---|---|---|
| value | string | The raw text content containing newlines to be formatted into HTML. |
| autoescape | boolean = False | Whether to escape HTML special characters in the input text before wrapping in tags. |
Returns
| Type | Description |
|---|---|
string | The input text wrapped in HTML paragraph tags with single newlines converted to line break tags. |