Filters › nl2br

Table of Contents

← filters

Filter nl2br:

  • no args

The nl2br filter inserts HTML line breaks before all newlines in a string:

{{ "I like Aspect.\nYou will like it too."|nl2br }}
{# outputs

    I like Aspect.<br />
    You will like it too.

#}