Lego2012
7/11/2017 - 6:47 AM

HTML in Variable

HTML in Variable

For example:

+++
title = "My test"
slogan = "This line needs a <br>break"
+++

In your template, try this:

{{ .Params.slogan | safeHTML }}

Also, you can do similar with Markdown:

{{ .Params.slogan | markdownify }}

Combine the above with TOML's multiline support, and you can get niceness.