Recently one of my friends told me about a language called markdown language. First I thought that it will be kinda boring, but as I’ve started writing on markdown I felt this was awesome.
So in today’s blog, we’ll be knowing about this awesome language. Also, I’ll introduce to you the software that I personally use for this language.
So let’s start with our first heading-
What is Markdown?
Markdown is a lightweight markup language that use to format plain text.
Means simply a markdown language is a language which beautifies a plain text document with different styles, like-
- Paragraph styles like bold,italic
- Hyperlink to other pages, files and so on.
Okay, now another thing. Here I use both the terms
- Markup language
- Markdown language
You can be confused to this part. I was also got confused for the first time.
You can also ask that-
- Hey, all this things we can do in HTML, so why markdown.
- Even is there any difference between these two languages?
So, now let’s see this thing first.
Are Markup and Markdown both same?
Markup and markdown are not the same things though they serve much the same purpose.
Both give us the option to format a plain text file.
- Markup is used to build web pages. It typically refers to HTML in general, where the plaintext content is “marked up” by adding tags that explain how that content should be structured and formatted.
Elements such as
<p>to layout the page and other markup tags such as
<span>to give structure to the writing.
Example of markup language(or HTML)-
- Now, Markdown is a pre processor for HTML. It’s a text based format that allows you to create different text styles easily without using any actual HTML.
For example, to create a heading element in markdown, you use the
#symbol in place of
<h1>. And it interprets into normal HTML code after writing.
Markdown is easy to write and understand at the same time.
A markdown looks like this-
Now if you have a site, where you let people post content, like us😁, then the people might want to use some markup to make their content looks better on the web.
- Markup has a big drawback that it creates a big security issue, called as Cross Site Security attacks or XSS attacks. In XSS attacks, a bad user writes a comment containing markup that causes the site to link to or load bad content. It might be a phishing scam or a malware link or some other nasty thing.
- Another issue was that many users just found HTML markup a big heavy, difficult to read or edit. Simplified markup languages(like Markdown) would be useful.
What is XSS Attack?
A Cross-Site Security attack is a kind of attack where a preparator finds out a vulnerability in a website that enables script injection. So the preparator injects a malicious code/script into the website which causes the user to lead to bad content and so on. By this attack, a website is never affected directly but the users are the main target of this kind of attack and they can be hugely affected.
Depending on the severity of the attack, user accounts may be affected like-
- page content modified
- misleading the users to somewhere, where they willingly share their private data.
- Session cookies could be revealed. So the perpetrator can impersonate valid users and access their private accounts.
Now, coming to our main question.
Why choose Markdown?
- Markdown can be used for literally everything. You can use it to create websites, documents, notes, books, presentations, email messages, and so on.
- Markdown is platform independent. You can write Markdown-formatted text on any device running any operating system.
- Markdown is portable. Files containing Markdown-formatted text can be opened using virtually any application. If you decide you don’t like the Markdown application you’re currently using, you can import your Markdown files into another Markdown application. That’s in stark contrast to word processing applications like Microsoft Word that lock your content into a proprietary file format.
- Markdown is future proof. Even if the application you’re using stops working at some point in the future, you’ll still be able to read your Markdown-formatted text using a text editing application. This is an important consideration when it comes to books, university theses, and other milestone documents that need to be preserved indefinitely.
- Markdown is everywhere. Websites like Reddit and GitHub support Markdown, and lots of desktop and web-based applications support it.
- The Best thing of markdown is that it is free of code and distraction free. So, the writers loves this. Also after writing a markdown file you can convert it into a bunch of formats like PDF, epub, Docx, HTML, etc.
Here is a small reference where you can find more information.
You’ll find the guide to format your file.