Markdown works now
This post is written in Markdown instead of AsciiDoc. The build picks the converter from the file extension: .adoc and .asciidoc go through asciidoctor, .md and .markdown go through markdown-it.
Metadata lives in a front matter block at the top, between two --- lines. It uses the same keys as the AsciiDoc :type: and :tags: attributes, so tag pages and the home list treat both formats the same.
What it supports
- Bold, italics,
strikethroughandinline code - Links and “smart quotes” that turn curly
- Tables, code blocks and quotes, all shown below
Alone I go fast. Together, we go far.
def read_markdown(filepath):
with open(filepath, encoding="utf-8") as f:
attrs, body = split_front_matter(f.read())
return attrs, parse_markdown_title(body), _markdown.render(body)
| Extension | Converter |
|---|---|
.adoc |
asciidoctor |
.md |
markdown-it |
That’s it.