Markdown Cheatsheet
This is an unnumbered prefix chapter for a brief Markdown cheatsheet, built with mdBook.
Defined in SUMMARY.md
as:
[Markdown Cheatsheet](./md/prefix.md)
The following chapters (on desktop, see left) are defined as:
- [CHAPTER X](./PATH/TO/*.md)
- [CHAPTER X.1](./PATH/TO/*.md)
General mdBook Structure
.
├── book
│ ├── ...
│ ├── webpage stuff
│ └── ...
├── book.toml
└── src
├── ...
├── *.md and images (can be nested)
├── ...
└── SUMMARY.md
Official mdBook Documentation
https://rust-lang.github.io/mdBook/index.html
Headings
Markdown
# Heading 1
## Heading 2
### Heading 3
#### Heading 4
##### Heading 5
###### Heading 6
renders as
Heading 1
Heading 2
Heading 3
Heading 4
Heading 5
Heading 6
Emphasis
Markdown
*Italics* or _Italics_
**Bold** or __Bold__
_**Combined**_
~~Strikethrough~~
renders as
Italics or Italics
Bold or Bold
Combined
Strikethrough
Lists
Markdown
1. First ordered list item
2. Second ordered list item
3. Third ordered list item (4 spaces)
- First Unordered list item
- Second unordered list item
- Third unordered list item (2 spaces)
- Another level of indentation
renders as
- First ordered list item
- Second ordered list item
- Third ordered list item (4 spaces)
- First Unordered list item
- Second unordered list item
- Third unordered list item (2 spaces)
- Another level of indentation
- Third unordered list item (2 spaces)
Tables
Markdown
Tables | Don't | Have | To | Be | Aligned
--- | --- | --- | --- | --- | ---
They | will | still | render | very | nicely
Emphasis | formatters | *also* | work | as | **expected **
renders as
Tables | Don't | Have | To | Be | Aligned |
---|---|---|---|---|---|
They | will | still | render | very | nicely |
Emphasis | formatters | also | work | as | expected |
Links
Markdown
<https://christianarndt.net>
[This is a link to a malicious website](https://www.google.com)
renders as
https://christianarndt.net
This is a link to a malicious website
Images
Markdown

***

renders as
Notes
- The
***
produces a horizontal line - Images cannot be rendered? ->
[...]
text is used - Hovering over the (non-existing) image will display the
"..."
content in a popup
Quotes
Markdown
> This is a quote
>> quoting this sentence.
>>> quoting a third sentence.
renders as
This is a quote
quoting this sentence.
quoting a third sentence.
Code Snippets
Markdown
Inline code has `back-ticks around` it.
```python
s = "hello"
print(s)
```
```rust
let s = "jello";
println!(s);
```
renders as
Inline code has back-ticks around
it.
s = "Jello"
print(s)
#![allow(unused)] fn main() { let s = "jello"; println!("{}", s); }
Notes
You can even run the rust code in here by clicking the play button. Fancy that.