Markdown Toolbox Logo Markdown Toolbox
Home
Blog

Cheat Sheet - GitHub Style Markdown

2023-12-12

GitHub Flavored Markdown (GFM) extends the standard Markdown syntax to include some additional features specific to GitHub. This cheat sheet covers key aspects of GFM, making it easier to create READMEs, issues, and other documentation on GitHub.

Extended Syntax

Task Lists

  • Create task lists with - [ ] for an incomplete task and - [x] for a completed task.

    -   [x] Completed task
    -   [ ] Incomplete task
    

Strikethrough

  • Use double tildes ~~ to strike through text.

    ~~Strikethrough~~
    

Tables

  • Create tables using hyphens - and pipes |.

    | Header 1 | Header 2 |
    | -------- | -------- |
    | Row 1    | Data 1   |
    | Row 2    | Data 2   |
    

Fenced Code Blocks

  • Use triple backticks (```) and specify a language for syntax highlighting.

    ```javascript console.log("Hello, world!"); ```

Mentioning Users and Teams

  • Use @username to mention a user or team.

Issue and Pull Request References

  • Reference issues and pull requests using #.

Standard Markdown Syntax

Headings

  • Use # for headers. More #s mean smaller headers.

Text Formatting

  • Bold: **bold**
  • Italic: *italic*
  • Bold and Italic: ***bold & italic***

Lists

  • Unordered List: Start with -, +, or *.
  • Ordered List: Start with numbers followed by ..

Links and Images

  • Link: [Title](URL)
  • Image: ![Alt text](URL)

Blockquotes

  • Use > for block quotes.

GitHub's Markdown allows for more interactive and dynamic documentation, especially useful in the context of collaborative projects.