Markdown Logo

What is Markdown?

  • Markdown is a lightweight markup language with a simple syntax designed for easy readability and writing. It’s ideal for writing blog posts, articles, or any content meant for the web.
  • Think of Markdown as an alternative to writing raw HTML, simplifying the formatting process. Markdown text is converted into valid HTML by a Markdown engine.

Headers

Create headings of different sizes using hash symbols (#):

Code: # Header 1 (Largest) 
Code: ## Header2
Code: ### Header3
  • Headers act like titles within your content. The number of hashes determines the header size (up to Header 6, the smallest).

Text Formatting

  • Italics:

text

_text_ or *text*

  • Bold:

text

__text__ or **text**
  • Strikethrough:

text

~~text~~

Lists

  • Unordered lists: Use asterisks (*), plus signs (+), or hyphens (-)
    • Item 1
    • Item 2
      * Item 1
      * Item 2
    
  • Ordered lists: Use numbers followed by periods
    1. Item 1
    2. Item 2
      1. Item 1
      2. Item 2 
    
  • Nested lists: Indent with spaces
    • Fruit
      • Apples
      • Oranges
      * Fruit
          * Apples
          * Oranges
    

Horizontal Rules

Three or more hyphens, asterisks, or underscores create a horizontal line:

---

Google’s Homepage: https://www.google.com “Visit Google”

Google's Homepage: [https://www.google.com](https://www.google.com) "Visit Google"
  • The text within the brackets is the clickable part; the URL for the link is in parentheses.

Images

see above picture
![Markdown Logo](/assets/images/markdown.png "Markdown Logo")
  • Similar to links, but with an exclamation mark (!) at the beginning. Alt text (within quotes) provides a description if the image fails to load.

Tables

Column Header 1 Column Header 2 Column Header 3
Data Cell 1 Data Cell 2 Data Cell 3
Data Cell 4 Data Cell 5 Data Cell 6
| Column Header 1 | Column Header 2 | Column Header 3 |
|---|---|---|
| Data Cell 1     | Data Cell 2     | Data Cell 3     |
| Data Cell 4     | Data Cell 5     | Data Cell 6     |

* Use pipes (|) to separate columns and hyphens (-) to create header rows.

Code Blocks

function greet(name) {
  console.log("Hello, " + name + "!");
}
  • Use three backticks (```) and specify the language for syntax highlighting.