一个时期是由一个以上的连接的行句组成,而一个以上的空行分裂划分出不同的区段(空行的定义是显示上看起来像是空行,就被认为是空行,例如有一行只有空白和tab,那该行也会被视为空行),一般的先前不需要用空白或换行缩进。
减价支持两种标题的语法,Setext和ATX形式.Setext形式是用底线的形式,利用=(最高阶标题)和-(第二阶标题),ATX形式在行首插入1到6个#,对应到标题1到6阶。
区块链引用则使用email形式的’ >’角括号。
Markdown语法:
A First Level Header ==================== A Second Level Header --------------------- Now is the time for all good men to come to the aid of their country. This is just a regular paragraph. The quick brown fox jumped over the lazy dog's back. ### Header 3 > This is a blockquote. > > This is the second paragraph in the blockquote. > > ## This is an H2 in a blockquote
输出HTML为:
<h1>A First Level Header</h1> <h2>A Second Level Header</h2> <p>Now is the time for all good men to come to the aid of their country. This is just a regular paragraph.</p> <p>The quick brown fox jumped over the lazy dog's back.</p> <h3>Header 3</h3> <blockquote> <p>This is a blockquote.</p> <p>This is the second paragraph in the blockquote.</p> <h2>This is an H2 in a blockquote</h2> </blockquote>