流星:如何渲染换行符? [英] Meteor: How to render line breaks?
本文介绍了流星:如何渲染换行符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有以下变量:hello↵↵world". (该值来自文本区域)
I have the following variable: "hello↵↵world". (the value is coming from a textarea)
问题是当我要求Meteor用{{content}}显示它时,所有内容都显示在同一行上,并且没有考虑换行符.
The problem is when I ask Meteor to display it with {{content}}, everything appears on the same line and the line break are not taken into account.
{{content}}
# renders
hello world
# should render
hello
world
推荐答案
用
<pre>
Any
amount of
formatting.
</pre>
<pre>
Any
amount of
formatting.
</pre>
这篇关于流星:如何渲染换行符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文