newline_to_br - Liquid Filter Reference - 1.1.0
| Filter Name | newline_to_br |
| Group | Text |
| Version | 1.1.0 |
Description
Inserts an HTML line break in front of each newline in a string.
Examples
{% capture string_with_newlines %}
Hello
there
{% endcapture %}
{{ string_with_newlines | newline_to_br }}
<br />
Hello<br />
there<br />
Back to Liquid Reference for 1.1.0
Back to Documentation