Markdown Basics
This page demonstrates the Markdown features supported by GitBook Online Generator.
Text Formatting
You can use bold text, italic text, ~~strikethrough~~, and inline code.
Combine them: bold and italic, bold with code.
Headings
Headings from # (H1) through ###### (H6) are supported. Each heading automatically gets an anchor ID for linking.
Links
Lists
Unordered List
- First item
- Second item
- Nested item A
- Nested item B
- Deep nested
- Third item
Ordered List
- First step
- Second step
- Sub-step 2a
- Sub-step 2b
- Third step
Blockquotes
This is a blockquote. It can contain formatted text and span multiple lines.
โ Author Name
ไปฃ็ ๅ (Code Blocks)
Python
def greet(name: str) -> str:
"""Generate a greeting message."""
return f"Hello, {name}! Welcome to the book."
if __name__ == "__main__":
message = greet("Reader")
print(message)
JavaScript
function buildTOC(tree, depth = 0) {
const ul = document.createElement("ul");
tree.forEach((node) => {
const li = document.createElement("li");
li.textContent = node.title;
if (node.children) {
li.appendChild(buildTOC(node.children, depth + 1));
}
ul.appendChild(li);
});
return ul;
}
Bash
#!/bin/bash
echo "Building book..."
python scripts/build.py
echo "Done! Output in dist/"
Images
Images use standard Markdown syntax:

Horizontal Rules
Three or more dashes create a horizontal rule:
Escaping
Use backslashes to escape special characters: *not italic*, `not code`.
Next: See advanced features like tables and diagrams.