markDown语法

2023/3/17 markdown

Markdown是一种轻量级标记语言,排版语法简洁,让人们更多地关注内容本身而非排版。它使用易读易写的纯文本格式编写文档,可与HTML混编,可导出 HTML、PDF 以及本身的 .md 格式的文件。因简洁、高效、易读、易写,Markdown被大量使用,如Github、Wikipedia、简书等。

官方教程 (opens new window)

# 基本语法

元素 语法
标题(Heading) # H1 ## H2 ### H3
粗体(Bold) **bold text**
斜体(Italic) *italicized text*
引用块(Blockquote) > blockquote
有序列表(Ordered List) 1. First item 2. Second item 3. Third item
无序列表(Unordered List) - First item - Second item - Third item
代码(Code) code
分隔线(Horizontal Rule) ---
链接(Link) [title](https://www.example.com)
图片(Image [title](https://www.example.com)

# 扩展语法

这些元素通过添加额外的功能扩展了基本语法。但是,并非所有 Markdown 应用程序都支持这些元素。

元素 语法
表格(Table) | Syntax | Description |
| ----------- | ----------- |
|Header | Title |
| Paragraph | Text |
代码块(Fenced Code Block) {"firstName": "John",
"lastName": "Smith",
"age": 25}
脚注(Footnote) Here's a sentence with a footnote. [^1]
[^1]: This is the footnote.
标题编号(Heading ID) ### My Great Heading {#custom-id}
定义列表(Definition List) term : definition
删除线(Strikethrough) ~~The world is flat.~~
任务列表(Task List) - [x] Write the press release
- [x] Write the press release
- [ ] Update the website
最后更新时间: 2023/7/16 15:32:35