DEV Community

divyangana98
divyangana98

Posted on

Some basics of Markdown

What exactly is Markdown?

Well, here’s how google defines Markdown,
“Markdown is a lightweight markup language for creating formatted text using a plain-text editor.”
In simple words, it is just an easy syntax that helps to format texts on the web page. The text we see on the web page is written in HTML which is a bit difficult for a normal user to understand, especially the ones who are not very familiar with it. To avoid these struggles markdown was introduced by John Gruber and Aaron Schwartz IN 2004. You can write in any text editor like Typora, Draft, MacDown, and VSCode(it is not a text editor but provides functionality to write markdown and preview it.

Where is markdown used?

It is used in blogging, README files, online forums, etc.
Now that we know what markdown is, let’s dive into its basics….
Things you can format in markdown are headings, links, blockquotes, images, blocks of code, and more. We’ll go through each one by one.

1. Headings

Heading sizes can be formatted using hash symbol like

# Heading 1

## Heading 2

### Heading 3

#### Heading 4

#####Heading 5

###### Heading 6

Heading 1

Heading 2

Heading 3

Heading 4

Heading 5
Heading 6

2. Italics

Use simple asterisk to make your text italic or you can use underscore. Example: *text* , _text_.

Italic with asterisk
italic with underscore

3. Bold

Use double asterisk for bold or you can also use double underscore for bold. Example **text** or __text__

text
text

4. Strikthrough

Use '~~' for strikethrough. ~~This text is strikethrough~~

This text is strikethrough

5. Horizontal Rule

Use '---' or '___(triple underscore)' for horizontal rule.

6. Blockquote

Use greater than symbol('>') for blockquote. It gives a background and blue line on the left side.

Blockquote

7. Links

[Link text ] (https://link-address.com) You can navigate to the given url by clicking on ‘Link’.

8. Unordered lists

  • Element 1
  • Element 2
    • element 1
    • element 2
  • Element 3

9. Ordered lists

  1. Item 1
  2. Item 2
  3. Item 3

10. Image

For image reference syntax is : ![Image text](https://image-address-here.com/img/icon256.png)

So, these were some basics of markdown.
You can also check out the syntax I used above in the README.md file
here

I hope this article was helpful. I’ll keep documenting my journey of learning through these blog posts.

Thank you ! Happy Learning!

Top comments (0)