This guide describes the Markdown syntax supported by Ceradoc. It is based on CommonMark with GitHub Flavored Markdown (GFM) extensions.
Document Structure
Links
Lists
Unordered Lists
Use *, -, or + for unordered lists:
* Item one
* Item two
* Item three
- Alternative syntax
- Using dashes
+ Another alternative
+ Using plus signsOrdered Lists
Use numbers followed by periods:
1. First item
2. Second item
3. Third itemThe actual numbers don’t matter:
1. First item
1. Second item # Will be numbered 2
1. Third item # Will be numbered 3Nested Lists
Indent list items for nesting:
* Level 1 item
* Level 2 item
* Level 3 item
* Back to level 1
1. First item
1. Nested item
2. Another nested
2. Second itemCode Blocks
Fenced Code Blocks
Use triple backticks or tildes:
```
Code block without language
```
```ruby
def hello_world
puts "Hello, World!"
end
```
~~~python
def hello_world():
print("Hello, World!")
~~~Tables (GFM)
Basic Tables
| Header 1 | Header 2 | Header 3 |
|----------|----------|----------|
| Cell 1 | Cell 2 | Cell 3 |
| Cell 4 | Cell 5 | Cell 6 |Extensions
Abbreviations
Define abbreviations:
The HTML specification is maintained by the W3C.
*[HTML]: Hyper Text Markup Language
*[W3C]: World Wide Web ConsortiumCeradoc-Specific Features
Supported Extensions
Ceradoc extends CommonMark with:
-
Definition lists - Using
Term: Definitionsyntax -
Abbreviations - Using
*[ABBR]: Definitionsyntax -
Footnotes - Using
[^n]: Definitionsyntax -
Attribute lists - Using
{: attributes }syntax -
Custom IDs - Using
{#id}syntax -
Task lists - Using
- [ ]syntax
Best Practices
CommonMark Compliance
Ceradoc aims for CommonMark compliance with these notes:
| Feature | Status | |---------|--------| | ATX Headings | ✓ Full support | | Setext Headings | ✓ Full support | | Indented code blocks | ✓ Full support | | Fenced code blocks | ✓ Full support | | Blockquotes | ✓ Full support | | Lists | ✓ Full support | | Thematic breaks | ✓ Full support | | Links | ✓ Full support | | Images | ✓ Full support | | Emphasis | ✓ Full support | | Code spans | ✓ Full support | | HTML blocks | Partial support | | HTML inline | Partial support | | Hard line breaks | ✓ Full support | | Soft line breaks | ✓ Full support |