Markdown sample
Comprehensive Markdown Syntax Guide
Section titled “Comprehensive Markdown Syntax Guide”This document demonstrates all the major syntactic constructs available in Markdown.
Headers
Section titled “Headers”H1 Header
Section titled “H1 Header”H2 Header
Section titled “H2 Header”H3 Header
Section titled “H3 Header”H4 Header
Section titled “H4 Header”H5 Header
Section titled “H5 Header”H6 Header
Section titled “H6 Header”Alternative H1
Section titled “Alternative H1”Alternative H2
Section titled “Alternative H2”Text Formatting
Section titled “Text Formatting”Bold text using asterisks Bold text using underscores
Italic text using asterisks Italic text using underscores
Bold and italic using asterisks Bold and italic using underscores
Strikethrough text
Inline code
Regular text with bold, italic, and code
mixed together.
Unordered Lists
Section titled “Unordered Lists”- Item 1
- Item 2
- Nested item 2.1
- Nested item 2.2
- Deeply nested item 2.2.1
- Item 3
Alternative syntax:
- Item A
- Item B
- Nested item B.1
- Nested item B.2
Another alternative:
- Item X
- Item Y
- Nested item Y.1
Ordered Lists
Section titled “Ordered Lists”- First item
- Second item
- Nested numbered item
- Another nested item
- Deeply nested item
- Third item
Alternative numbering:
- Item one
- Item two (auto-numbered)
- Item three (auto-numbered)
Mixed Lists
Section titled “Mixed Lists”- Ordered item
- Unordered nested item
- Another unordered nested item
- Another ordered item
- Nested ordered item
- Another nested ordered item
Task Lists
Section titled “Task Lists”- Completed task
- Incomplete task
- Another completed task
- Nested completed task
- Nested incomplete task
Links and Images
Section titled “Links and Images”// TODO turn off MDX < https://www.autolink.com>
Case-insensitive reference link
You can also link to local files.
Images
Section titled “Images”Reference Definitions
Section titled “Reference Definitions”Inline Code
Section titled “Inline Code”Use console.log()
to print to the console.
Code Blocks
Section titled “Code Blocks”Simple code block without syntax highlighting
// JavaScript code blockfunction greet(name) { console.log(`Hello, ${name}!`);}
greet("World");
# Python code blockdef fibonacci(n): if n <= 1: return n return fibonacci(n-1) + fibonacci(n-2)
print(fibonacci(10))
# Bash script#!/bin/bashecho "Hello, World!"for i in {1..5}; do echo "Number: $i"done
{ "name": "Sample JSON", "version": "1.0.0", "dependencies": { "express": "^4.18.0" }}
Indented code block (4 spaces): TODO: fix this parse issue
Tables
Section titled “Tables”Column 1 | Column 2 | Column 3 |
---|---|---|
Row 1 | Data | More data |
Row 2 | Info | Details |
Table with Alignment
Section titled “Table with Alignment”Left Aligned | Center Aligned | Right Aligned |
---|---|---|
Left | Center | Right |
Text | Text | Text |
More | Data | Here |
Simple Table
Section titled “Simple Table”First Header | Second Header |
---|---|
Content cell 1 | Content cell 2 |
Content cell 3 | Content cell 4 |
Blockquotes
Section titled “Blockquotes”This is a simple blockquote.
This is a blockquote that spans multiple lines.
Nested blockquotes:
This is a nested blockquote.
And this is deeply nested.
Blockquote with other elements
Section titled “Blockquote with other elements”
- List item in blockquote
- Another item
Bold text in blockquote with
inline code
.
Horizontal Rules
Section titled “Horizontal Rules”Line Breaks
Section titled “Line Breaks”This is the first line.
This is the second line (two spaces at end of previous line).
This is the third line.
This is the fourth line (empty line creates paragraph break).
This is a line with a
backslash line break.
HTML Elements
Section titled “HTML Elements”You can use HTML tags in Markdown.
Bold using HTML
Inline code using HTML
Ctrl + C
Highlighted text
Small text
Subscript and Superscript
Expandable section
This content is hidden by default and can be expanded.
- List item
- Another item
console.log("Code in details");
Advanced Features
Section titled “Advanced Features”Footnotes
Section titled “Footnotes”Here’s a sentence with a footnote1.
Another sentence with a footnote2.
Definition Lists
Section titled “Definition Lists”Term 1 : Definition for term 1
Term 2 : Definition for term 2 : Another definition for term 2
Abbreviations
Section titled “Abbreviations”_[HTML]: Hyper Text Markup Language _[CSS]: Cascading Style Sheets
HTML and CSS are important web technologies.
Mathematics (if supported)
Section titled “Mathematics (if supported)”Inline math: $E = mc^2$
Block math:
$$ \int_{-\infty}^{\infty} e^{-x^2} dx = \sqrt{\pi} $$
Escape Characters
Section titled “Escape Characters”Use backslashes to escape special characters:
*Not italic* #Not a header [Not a link] `Not code`
Comments
Section titled “Comments”Emojis
Section titled “Emojis”:smile: :heart: :thumbsup: :rocket: :computer:
😀 😍 👍 🚀 💻
GitHub Alerts in Markdown
Section titled “GitHub Alerts in Markdown”GitHub supports custom alerts in Markdown files, which can be used to highlight important information or warnings. Here are some examples of how to use them:
[!NOTE] Useful information that users should know, even when skimming content.
[!TIP] Helpful advice for doing things better or more easily.
[!IMPORTANT] Key information users need to know to achieve their goal.
[!WARNING] Urgent info that needs immediate user attention to avoid problems.
[!CAUTION] Advises about risks or negative outcomes of certain actions.
Conclusion
Section titled “Conclusion”This document covers most of the standard Markdown syntax. Some features like footnotes, definition lists, mathematics, and certain HTML elements may not be supported in all Markdown processors, but they work in many extended versions like GitHub Flavored Markdown (GFM), CommonMark, and others.
Note: The exact rendering of these elements may vary depending on the Markdown processor being used.