Home >Web Front-end >JS Tutorial >Detailed explanation of how to write newline spaces (multiple spaces) in WeChat mini programs_javascript skills

Detailed explanation of how to write newline spaces (multiple spaces) in WeChat mini programs_javascript skills

无忌哥哥
无忌哥哥Original
2018-07-12 14:06:403153browse

This article mainly introduces the detailed explanation of how to write line breaks (multiple spaces) in WeChat mini programs. It is very good and has certain reference value. Friends in need can refer to it

HTML in mini programs The web page entity cannot be used normally. The writing method in the mini program is:

1. Space, line break

28f128881ce1cdc57a572953e91f7d0fHello! \tJuly is on fire! \nI am on the next line273e21371c5d5e701d3c98517a0bfa41

\t Space (only one space will be displayed if multiple)
\n Line break

2. Continuous spaces

<view>
  <text space="ensp">你好 啊   哈哈哈(空格是中文字符一半大小)</text>
</view>
<view>
  <text space="emsp">你好 啊   哈哈哈(空格是中文字符大小)</text>
</view>
<view>
  <text space="nbsp">你好 啊   哈哈哈(空格根据字体设置)</text>
</view>
<view>
  <text decode="{{true}}">你好 啊   哈哈哈(空格是中文字符一半大小)</text>
</view>
<view>
  <text decode="{{true}}">你好 啊   哈哈哈(空格是中文字符大小)</text>
</view>
<view>
  <text decode="{{true}}">你好 啊   哈哈哈(空格根据字体设置)</text>
</view>

Friendly reminder: Must be in the 28f128881ce1cdc57a572953e91f7d0f tag!

The above is the detailed content of Detailed explanation of how to write newline spaces (multiple spaces) in WeChat mini programs_javascript skills. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn