Newlines are not HTML escaped
Snafuuz opened this issue · 2 comments
Snafuuz commented
The mustache documentation says:
"All variables are HTML escaped by default."
The documentation is not very explicit about newlines in this context, but I think they should be converted to
tags, so a value can also have multiple lines and still be rendered correctly, including line breaks.
The problem can of course be avoided by using a custom escaping function, but I assume the correct behaviour would be to translate newlines into
by default
Snafuuz commented
=> I filed a pull request with a change that adds newline conversion to the HTML escape function
#19
kainjow commented
See my comments in the PR.