Sample document¶
This document demonstrate reStructuredText syntax. Professional books and tech documentation are plain text files written with this easy markup language.
Tip
You can try https://snippets.documatt.com, the online editor with preview useful for learning and testing reStructuredText without installing it.
Inline elements¶
Paragraphs may contain emphasised, strong emphasised words. Links to external webs like https://documatt.com/blog/ are auto-recognized. Sometimes you need monospaced text
. Useful are also superscript or subscript.
Images¶
Lists¶
Unordered lists usually use *
as bullet symbol:
A bullet list item
Second item
A sub item
Ordered (enumerated) lists that is auto-numbered starts with #.
:
one
two
three
Showing code examples¶
It’s easy to show code parts with inline literal
, or literal block:
some literal text
Or, literal block with syntax highlighting:
for (let i = 0; i < 3; i++) { // shows 0, then 1, then 2
alert(i);
}