1.样式一
<view>
<text>第一段文字</text>
<text>第二段文字</text>
</view>
这样是不会换行的!
2.样式二
<view>
<text class="flex flex-direction">第一段文字</text>
<text class="flex flex-direction">第二段文字</text>
</view>
这样就可以换行了^v^!
注:(适用与多数不会自动换行的标签,关键样式class="flex flex-direction")
有些人会说直接<br/>不就好了吗?你试试用<br/>标签运行到小程序模拟器是什么效果。我之前试过,在HBuilder X中<br/>不会报错,到了小程序中<br/>就报错!
转载请带上我啊!