将
text
组件的
decode
属性设置为
true
就可以在
text
组建里使用 html编码后的字符和转义字符了,如:
<text decode='true'> \n</text>
复制
这里面
 
和
\n
表示一个空格和回车。