How to create a readme.md? The Markdown Markup Language: Syntax and Usage

How to create a readme.md? The Markdown Markup Language: Syntax and Usage

Subscribe to my newsletter and never miss my upcoming articles

Markdown is a lightweight markup language for adding formatting to regular text documents.

Using Markdown

Most people use Markdown for content creation, such as blog articles or email newsletters. Most git repos have a README.md file that contains a Markdown description of the project. You can style messages on Slack, Discord, StackOverflow, Reddit, and WhatsApp using Markdown. Various documentation generation utilities support Markdown, such as JSDoc.

There are several online editors, such as Dillinger. You can use it to see how Markdown is converted to html. Open the site and start typing in the left pane. A preview of the document appears in the right pane.

Also, you can write formatted text in a regular file with the extension ".md" or ".markdown". To convert formatted text to html, pdf or other formats, you need to use a special application (for example, Dillinger). These applications use the Markdown processor to read the text and convert it to the desired format. There are various implementations of such processors, for example remark.

Markdown syntax

Special characters are used to format text. If you put a # symbol at the beginning of a line, then this line will be perceived as a heading of the first level. Following is the syntax for the various elements.

Headings

# First level heading
## Second level heading
### Third level heading

Italics

*Italicized text*

Bold text

**Bold text**

Strikethrough text

~~Strikethrough text~~

Quote

> Quote text

Ordered list

1. First point
2. Second point
3. Third point

Unordered list

- First point
- Second point
- Third point

Task list

- [x] First task
- [ ] Second task
- [ ] Third task

Inline code

`let age = 25`

Multi-line code

```
const postsMarkup = useMemo(() => {
  return getPostsMarkup(posts, theme);
}, [posts, theme]);
```
[Google](https://www.google.com/)

Image

![Alternative text](https://picsum.photos/320/200)

Table

| Name | Surname |
| ----------- | ----------- |
| Ivan | Petrov |
| Petro | Ivanov |

Table

| Name | Surname |
| ----------- | ----------- |
| Ivan | Petrov |
| Petro | Ivanov |

Horizontal line

---
 
Share this