Markdown Syntax

Qiandu supports Markdown for writing content, creating lists, etc. This page will show you some of the most common Markdown syntax examples used by Qiandu.

Markdown Basics

Text Styles

StyleSyntaxExampleOutput
Bold**bold text****bold text**bold text
Italic*italicized text*`italicized textitalicized text
Strikethrough~~strikethrough text~~~~strikethrough text~~strikethrough text
Subscript<sub></sub>This is a <sub>subscript</sub> textThis is a subscript text
Superscript<sup></sup>This is a <sup>superscript</sup> textThis is a superscript text

Quote

Block quote with superscript:

Don’t communicate by sharing memory, share memory by communicating.
Rob Pike1

Markdown
> Don't communicate by sharing memory, share memory by communicating.<br>
> — <cite>Rob Pike[^1]</cite>

[^1]: The above quote is excerpted from Rob Pike's [talk](https://www.youtube.com/watch?v=PAAkCSZUG1c) during Gopherfest, November 18, 2015.

Tables

Tables are not part of the core Markdown specification, but Hugo supports them out of the box:

NameAge
Bob27
Alice23
Markdown
|   Name | Age  |
|--------|------|
|    Bob | 27   |
|  Alice | 23   |

Inline in Markdown tables

ItalicsBoldCode
italicsboldcode
Markdown
| Italics   | Bold     | Code   |
| --------  | -------- | ------ |
| *italics* | **bold** | `code` |

Code Block

List

Ordered list

  1. First item
  2. Second item
  3. Third item
Markdown
1. First item
2. Second item
3. Third item

Unordered list

  • List item
  • Another item
  • And another item
Markdown
* List item
* Another item
* And another item

Nested Lists

  • Fruit
    • Apple
    • Orange
    • Banana
  • Dairy
    • Milk
    • Cheese
Markdown
* Fruit
  * Apple
  * Orange
  * Banana
* Dairy
  * Milk
  * Cheese

picture

landscape

Markdown
![landscape](https://picsum.photos/800/600)

With title:

landscape
Unsplash Landscape

Markdown
![landscape](https://picsum.photos/800/600 "Unsplash Landscape")

Configuration

Qiandu uses Goldmark to parse Markdown. Markdown rendering can be configured in markup.goldmark in hugo.yaml by contacting the community administrator. The following is the default configuration of Qiandu:

hugo.yaml
markup:
  goldmark:
    renderer:
      unsafe: true
  highlight:
    noClasses: false

For more options, go to Configure Markup.

MD Reference


  1. The above quote is excerpted from Rob Pike’s talk during Gopherfest, November 18, 2015. ↩︎