{"id":13625548,"url":"https://github.com/atapas/markdown-cheatsheet","last_synced_at":"2025-10-24T02:09:54.766Z","repository":{"id":37984594,"uuid":"498971132","full_name":"atapas/markdown-cheatsheet","owner":"atapas","description":"A single place for all the markdown syntaxes I have learned so far.","archived":false,"fork":false,"pushed_at":"2022-10-26T09:55:57.000Z","size":1695,"stargazers_count":242,"open_issues_count":36,"forks_count":82,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-03-31T06:06:32.001Z","etag":null,"topics":["github","hacktoberfest","markdown","open-source"],"latest_commit_sha":null,"homepage":"https://tapasadhikary.com","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/atapas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":["atapas"]}},"created_at":"2022-06-02T02:56:51.000Z","updated_at":"2025-03-08T13:42:38.000Z","dependencies_parsed_at":"2022-07-12T00:15:10.735Z","dependency_job_id":null,"html_url":"https://github.com/atapas/markdown-cheatsheet","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atapas%2Fmarkdown-cheatsheet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atapas%2Fmarkdown-cheatsheet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atapas%2Fmarkdown-cheatsheet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atapas%2Fmarkdown-cheatsheet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/atapas","download_url":"https://codeload.github.com/atapas/markdown-cheatsheet/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247615385,"owners_count":20967184,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["github","hacktoberfest","markdown","open-source"],"created_at":"2024-08-01T21:01:57.530Z","updated_at":"2025-10-24T02:09:54.742Z","avatar_url":"https://github.com/atapas.png","language":null,"readme":"\n# Table of Contents\n` markdown-cheatsheet` is a single place for all the markdown syntaxes I have learned so far. Sharing publicly so that you also know about them and use.\n\n1. [Headings](#headings)\n2. [Code](#code)\n3. [Unordered List of Items](#unordered-list-of-items)\n4. [Ordered List of Items](#ordered-list-of-items)\n5. [CheckBox Task List](#checkbox-task-list)\n6. [Code Block](#code-block)\n7. [Strikethrough Text](#strikethrough-text)\n8. [Blockquote Text](#blockquote-text)\n9. [Bold](#bold)\n10. [Italic](#italic)\n11. [Bold and Italic](#bold-and-italic)\n12. [Link](#link)\n13. [Image](#image)\n14. [Linking an Image](#linking-an-image)\n15. [Emojis](#emojis)\n16. [Alerts](#alerts)\n17. [Table](#table)\n18. [Table With Alignments](#table-with-alignments)\n19. [Horizontal Line](#horizontal-line)\n20. [HTML](#html)\n21. [Embed YouTube Video](#embed-youtube-video)\n22. [Mathematical Expressions](#mathematical-expressions)\n23. [DropDown](#dropdown)\n24. [Diagrams](#diagrams)\n25. [FootNote](#footnote)\n26. [Comments](#comments)\n\nMany Thanks to all the `Stargazers` who has supported this project with stars(⭐)\n\n[![Thanks to all stargazers](https://git-lister.onrender.com/api/stars/atapas/markdown-cheatsheet?limit=15)](https://github.com/atapas/markdown-cheatsheet/stargazers)\n\n## Headings\n\n**Syntax:**\n\n```\n# H1 - Heading 1\n## H2 - Heading 2\n### H3 - Heading 3\n#### H4 - Heading 4\n##### H5 - Heading 5\n###### H6 - Heading 6\n```\n**Output:**\n\n# H1 - Heading 1\n## H2 - Heading 2\n### H3 - Heading 3\n#### H4 - Heading 4\n##### H5 - Heading 5\n###### H6 - Heading 6\n\n## Code\n\n**Syntax:**\n\n```\n`This is Code`\n```\n\n**Output:**\n\n`This is Code`\n\n## Unordered List of Items\n\n**Syntax:**\n\n```\n- Milk\n- Tea\n- Beer\n```\n\n**Output:**\n\n- Milk\n- Tea\n- Beer\n\n**Syntax:**\n\u003e This is an alternate syntax to create unordered list items.\n\n```\n* JavaScript\n* TypeScript\n* ReactJs\n```\n\n**Output:**\n\n* JavaScript\n* TypeScript\n* ReactJs\n\n## Ordered List of Items\n\n**Syntax:**\n\n```\n1. Eat\n1. Walk\n1. Sleep\n```\n\n**Output:**\n\n1. Eat\n1. Walk\n1. Sleep\n\n## CheckBox Task List\n\n**Syntax:**\n\n```\n- [X] Code\n- [ ] Review\n- [ ] Commit\n```\n\n**Output:**\n\n- [X] Code\n- [ ] Review\n- [ ] Commit\n\n## Code Block\n\n**Syntax:**\n\n````\n```\nThis is a code block. You can create for code syntaxes like JavaScript, HTML, CSS, Bash, and many more.\n```\n````\n\n**Output:**\n```\nThis is a code block. You can create for code syntaxes like JavaScript, HTML, CSS, Bash, and many more.\n```\n\nIn order to ***highlight the code***, you can add language name at the start of the backticks as in the following examples.\n\n**Example 1:**\n\n````\n```js\nfunction print() {\n console.log('This is is a JavaScript Code Block');\n}\n```\n````\n\n**Output:**\n```js\nfunction print() {\n console.log('This is is a JavaScript Code Block');\n}\n```\n\n**Example 2:**\n\n````\n```bash\n# This is bash\necho 1\n```\n````\n\n**Output:**\n```bash\n# This is bash\necho 1\n```\n\n## Strikethrough Text\n\n**Syntax:**\n\n```\n~~Sharing is NOT about Caring.~~\n```\n\n**Output:**\n\n~~Sharing is NOT about Caring.~~\n\n## Blockquote Text\n\n**Syntax:**\n\n```\n\u003e When I say something, I mean it. When I mean it, I do it. When I do, I may fail. When I fail, I start talking about it again!\n```\n\n**Output:**\n\n\u003e When I say something, I mean it. When I mean it, I do it. When I do, I may fail. When I fail, I start talking about it again!\n\n## Bold\n\n**Syntax:**\n\n```\n**DO NOT UNDERESTIMATE THE POWER OF A PROGRAMMER.**\n```\n\n**Output:**\n\n**DO NOT UNDERESTIMATE THE POWER OF A PROGRAMMER.**\n\n## Italic\n\n**Syntax:**\n\n```\n*It is Written in Italics*\n```\n\n**Output:**\n\n*It is Written in Italics*\n\n## Bold and Italic\n\n**Syntax:**\n\n```\n***You Can Combine Bold and Italics***\n```\n\n**Output:**\n\n***You Can Combine Bold and Italics***\n\n## Link\n\n**Syntax:**\n\n```\nDid you know I have [Website](https://tapasadhikary.com)?\n```\n\n**Output:**\n\nDid you know I have [Website](https://tapasadhikary.com)?\n\n## Image\n\n**Syntax:**\n\n```\n![alt text](image)\n```\n\n**Output:**\n\n![GreenRoots Blog](https://res.cloudinary.com/atapas/image/upload/v1598936159/profile/500x500_oklccx.png)\n\n## Linking an Image\n\n**Syntax:**\n\n```\n[![alt text](image)](hyperlink)\n```\n\n**Output:**\n\n[![GreenRoots Blog](https://res.cloudinary.com/atapas/image/upload/v1598936159/profile/500x500_oklccx.png)](https://blog.greenroots.info)\n\n## Image Based on Theme\n\n**Syntax:**\n\n```\n![alt text](image#gh-dark-mode-only)\n```\nor\n```\n![alt text](image#gh-light-mode-only)\n```\n\n**Output (try changing themes!):**\n\n![dark mode only image](https://user-images.githubusercontent.com/73202594/194573255-096947e8-38af-44cb-b9dd-015132634c75.png#gh-dark-mode-only)\n\n![light mode only image](https://user-images.githubusercontent.com/73202594/194573460-55fcb36f-efed-4a82-8e3a-bd262cc4bfde.png#gh-light-mode-only)\n\n\n## Emojis\n\n**Syntax:**\n\n```\n:mango: :lemon: :man: :car:\n```\n\n**Output:**\n\n:mango: :lemon: :man: :car:\n\n## Alerts\n\n**Syntax:**\n\n```markdown\n\u003e [!NOTE]\n\u003e Git commits are snapshots of your code at a given time.\n```\n\n**Output:**\n\n\u003e [!NOTE]\n\u003e Git commits are snapshots of your code at a given time.\n\n**Syntax:**\n\n```markdown\n\u003e [!TIP]\n\u003e Use `git status` often to stay aware of your changes.\n```\n\n**Output:**\n\n\u003e [!TIP]\n\u003e Use `git status` often to stay aware of your changes.\n\n**Syntax:**\n\n```markdown\n\u003e [!IMPORTANT]\n\u003e Always commit your changes before switching branches to avoid losing work.\n```\n\n**Output:**\n\n\u003e [!IMPORTANT]\n\u003e Always commit your changes before switching branches to avoid losing work.\n\n**Syntax:**\n\n```markdown\n\n\u003e [!WARNING]\n\u003e Don’t use `git push --force` unless you fully understand the consequences.\n```\n\n**Output:**\n\n\u003e [!WARNING]\n\u003e Don’t use `git push --force` unless you fully understand the consequences.\n\n**Syntax:**\n\n```markdown\n\u003e [!CAUTION]\n\u003e Renaming branches in shared repositories can confuse collaborators.\n```\n\n**Output:**\n\n\u003e [!CAUTION]\n\u003e Renaming branches in shared repositories can confuse collaborators.\n\n## Table\n\n**Syntax:**\n\n```\n| Fruit | Emoji |\n| ----------- | ----------- |\n| Mango | :mango: |\n| Lemon | :lemon: |\n```\n\n**Output:**\n\n\n| Fruit | Emoji |\n| ----------- | ----------- |\n| Mango | :mango: |\n| Lemon | :lemon: |\n\n## Table With Alignments\n\n**Syntax:**\n\n```\n| Fruit(left)      | Emoji(center) | Taste(right)     |\n| :---        |    :----:   |          ---: |\n| Mango is the king of Fruits      | :mango:       | Sweet and I love it  |\n| Lemon is good for health   | :lemon:        | Sour, mix it in the water     |\n```\n\n**Output:**\n\n| Fruit(left)      | Emoji(center) | Taste(right)     |\n| :---        |    :----:   |          ---: |\n| Mango is the king of Fruits      | :mango:       | Sweet and I love it  |\n| Lemon is good for health   | :lemon:        | Sour, mix it in the water     |\n\n## Horizontal Line\n\n**Syntax:**\n\n```\n---\n```\n\n**Output:**\n\n---\n\n## HTML\n\n**Syntax:**\n\n```\n\u003cp align=\"center\"\u003e\n Yes, you can use allowed raw HTML in mark-down file.\n This is a paragraph aligned in the center.\n\u003c/p\u003e\n```\n\n**Output:**\n\n\u003cp align=\"center\"\u003e\n Yes, you can use allowed raw HTML in mark-down file.\n This is a paragraph aligned in the center.\n\u003c/p\u003e\n\n\u003cdetails\u003e\n    \u003csummary\u003eHeading\u003c/summary\u003e\n    The details are here.\n\u003c/details\u003e\n\n## Embed YouTube Video\n\n**Syntax:**\n\n```\n[![Alt Text](Thumbnail Image)](YOUTUBE VIDEO LINK)\n```\n\n**Output:**\n\n[![Forking a Repo](https://res.cloudinary.com/atapas/image/upload/v1654144800/demos/Merge-Conflicts_vtk8on.png)](https://www.youtube.com/watch?v=OulZeVtZhZQ)\n\n## Mathematical Expressions\n\n1. **Inline expressions:**\n\n    **Syntax**\n\n    ```plain\n    $\u003c\u003cmathematical expression\u003e\u003e$\n    ```\n\n    Replace `\u003c\u003cmathematical expression\u003e\u003e` with your expression.\n\n    **Example**\n\n    ```plain\n    $\\sqrt{3}+1$\n    ```\n\n    **Output**\n\n    $\\sqrt{3}+1$\n\n2. **Block Expressions:**\n\n    **Syntax**\n\n    ```plain\n    $$\u003c\u003cmathematical expression\u003e\u003e$$\n    ```\n\n    **Example**\n\n    ```plain\n    $$\\sqrt{3}+1$$\n    ```\n\n    **Output**\n\n    $$\\sqrt{3}+1$$\n\n3. **Mixed Expressions:**\n\n    **Syntax**\n    \n    ```\n    When $a \\ne 0$, there are two solutions to $(ax^2 + bx + c = 0)$ and they are \n    \n    $$ x = {-b \\pm \\sqrt{b^2-4ac} \\over 2a} $$\n    ```\n\n    **Output**\n\n    When $a \\ne 0$, there are two solutions to $(ax^2 + bx + c = 0)$ and they are \n    \n    $$ x = {-b \\pm \\sqrt{b^2-4ac} \\over 2a} $$\n\nFor more information on how to write mathematical expressions, [visit this page](https://en.wikibooks.org/wiki/LaTeX/Mathematics).\n\n## DropDown\n\n1. DropDown with Open:\n \u003cbr\u003e**Syntax**\n ```\n \u003cdetails open\u003e\n \u003csummary\u003eWant to know more? \u003c/summary\u003e\n \u003cbr\u003e\n This is called a DropDown.\n \u003cbr\u003eYes! This is possible using Markdown.\n \u003cbr\u003eYou can hide some content from the user.\n \u003cbr\u003eThey can view the detailed message only when they click.\n \u003c/details\u003e\n ```\n **Output**\n \u003cdetails open\u003e\n \u003csummary\u003eWant to know more?\u003c/summary\u003e\n \u003cbr\u003e\n This is called a DropDown.\n \u003cbr\u003eYes! This is possible using Markdown.\n \u003cbr\u003eYou can hide some content from the user.\n \u003cbr\u003eThey can view the detailed message only when they click.\n \u003c/details\u003e\n\n **Explanation**\n \u003cbr\u003eThe *details* tags are used to indicate that we want a dropdown.\n \u003cbr\u003eThe keyword *open* in details tag is causing the dropdown to stay opened even before the user clicks on it, which messes up the fun!\n \u003cbr\u003eIt looks like a question and answer - this is not our purpose, we fix this in the below example.\n \u003cbr\u003eBetween the *summary* tags, we write the heading/content to be displayed.\n \u003cbr\u003eAfter *summary*, we can include the detailed content.\n \u003cbr\u003eHowever, when a user clicks on the arrow, the detailed content gets hidden; with another the click, the content is displayed again.\n\n2. DropDown without Open:\n \u003cbr\u003e**Syntax**\n ```\n \u003cdetails\u003e\n \u003csummary\u003eWant to know more? Click Here\u003c/summary\u003e\n \u003cbr\u003e\n This is called a DropDown.\n \u003cbr\u003eYes! This is possible using Markdown.\n \u003cbr\u003eYou can hide some content from the user.\n \u003cbr\u003eThey can view the detailed message only when they click.\n \u003c/details\u003e\n ```\n **Output**\n \u003cdetails\u003e\n \u003csummary\u003eWant to know more? Click Here\u003c/summary\u003e\n \u003cbr\u003e\n This is called a DropDown.\n \u003cbr\u003eYes! This is possible using Markdown.\n \u003cbr\u003eYou can hide some content from the user.\n \u003cbr\u003eThey can view the detailed message only when they click.\n \u003c/details\u003e\n\n **Explanation**\n \u003cbr\u003eThe *details* tags are used to indicate that we want a dropdown.\n \u003cbr\u003eThis is what we require, the detailed content should be hidden initially. With a click, the information should be displayed.\n \u003cbr\u003eBetween the *summary* tags, we write the heading/content to be displayed inside or what we refer to as **DROPDOWN TITLE**.\n \u003cbr\u003eAfter *summary*, we can include the detailed content, this will be shown only when the user clicks the dropdown title.\n\n## Diagrams\n\n**Syntax:**\n- Use the *mermaid* syntax\n- Additional syntax: TD means Top Down, LR means Left Right, BT means Bottom Top, RL means Right Left \n\nTD variant\n```\n    ```mermaid\n        graph TD;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n    ```\n```\n\n**Output:**\n\n ```mermaid\n        graph TD;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n```\n\nLR variant\n```\n    ```mermaid\n        graph LR;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n    ```\n```\n\n**Output:**\n\n ```mermaid\n        graph LR;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n```\n\nBT variant\n```\n    ```mermaid\n        graph BT;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n    ```\n```\n\n**Output:**\n\n ```mermaid\n        graph BT;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n```\n\nRL variant\n```\n    ```mermaid\n        graph RL;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n    ```\n```\n\n**Output:**\n\n ```mermaid\n        graph RL;\n            A--\u003eB;\n            B--\u003eC;\n            C--\u003eD;\n            D--\u003eE;\n```\n\n## FootNote\n\n**Explanation:**\n\u003cbr\u003eFootnotes allow you to add notes and references without cluttering the body of the document. \n\u003cbr\u003eWhen you create a footnote, a superscript number with a link appears where you added the footnote reference. \n\u003cbr\u003eReaders can click the link to jump to the content of the footnote at the bottom of the page.\n\n**Syntax:**\n\n```\nHere's a simple footnote,[^1] and here's a longer one.[^bignote]\n\n[^1]: This is the first footnote.\n\n[^bignote]: Here's one with multiple paragraphs and code.\n\n```\n**Output:**\n\nHere's a simple footnote,[^1] and here's a longer one.[^bignote]\n\n[^1]: This is the first footnote.\n\n[^bignote]: Here's one with multiple paragraphs and code.\n\n\n## Comments\n\n**Explanation:**\n\u003cbr\u003eComments are text notes added to a program or a document to provide explanatory information.\n\u003cbr\u003eYou can hide content from the rendered Markdown by placing the content in a comment.\n\n\n**Syntax**\n\n```\nThis is Line Number 1. \n\u003c!---This is Line Number 2 and would not be rendered as this is a comment. ---\u003e\nThis is Line Number 3.\n```\n\n**Output**\n\nThis is Line Number 1. \n\u003c!---This is Line Number 2 and would not be rendered as this is a comment. ---\u003e\nThis is Line Number 3.\n","funding_links":["https://github.com/sponsors/atapas"],"categories":["Others"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatapas%2Fmarkdown-cheatsheet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fatapas%2Fmarkdown-cheatsheet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatapas%2Fmarkdown-cheatsheet/lists"}