Markdown Markup

Markdown

markup
md
introduction
Introduction to MD
Author

albertprofe

Published

Tuesday, June 1, 2021

Modified

Friday, November 1, 2024

1 What is Markdown?

📘 Markdown

Markdown is a lightweight markup language that you can use to add formatting elements to plaintext text documents.

Created by John Gruber in 2004, Markdown is now one of the world’s most popular markup languages.


Markdown Guide getting started

Using Markdown is different than using a WYSIWYG editor. When you create a Markdown-formatted file, you add Markdown syntax to the text to indicate which words and phrases should look different.

For example, to denote a heading, you add a number sign before it (e.g., # Heading One). Or to make a phrase bold, you add two asterisks before and after it (e.g., this text is bold). It may take a while to get used to seeing Markdown syntax in your text, especially if you’re accustomed to WYSIWYG applications. The screenshot below shows a Markdown file displayed in the Visual Studio Code text editor.

2 How Does it Work?

Dillinger makes writing in Markdown easy because it hides the stuff happening behind the scenes, but it’s worth exploring how the process works in general.

When you write in Markdown, the text is stored in a plaintext file that has an .md or .markdown extension. But then what? How is your Markdown-formatted file converted into HTML or a print-ready document?

The short answer is that you need a Markdown application capable of processing the Markdown file. There are lots of applications available — everything from simple scripts to desktop applications that look like Microsoft Word. Despite their visual differences, all of the applications do the same thing. Like Dillinger, they all convert Markdown-formatted text to HTML so it can be displayed in web browsers.

Markdown processor

Markdown applications use something called a Markdown processor (also commonly referred to as a “parser” or an “implementation”) to take the Markdown-formatted text and output it to HTML format. At that point, your document can be viewed in a web browser or combined with a style sheet and printed. You can see a visual representation of this process below.

Markdown app

The Markdown application and processor are two separate components. For the sake of brevity, I’ve combined them into one element (“Markdown app”) in the figure below. The Markdown Process

How Does it Work?

How Does it Work?

To summarize, this is a four-part process:

  1. Create a Markdown file using a text editor or a dedicated Markdown application. The file should have an .md or .markdown extension.
  2. Open the Markdown file in a Markdown application.
  3. Use the Markdown application to convert the Markdown file to an HTML document.
  4. View the HTML file in a web browser or use the Markdown application to convert it to another file format, like PDF.

From your perspective, the process will vary somewhat depending on the application you use. For example, Dillinger essentially combines steps 1-3 into a single, seamless interface — all you have to do is type in the left pane and the rendered output magically appears in the right pane. But if you use other tools, like a text editor with a static website generator, you’ll find that the process is much more visible.

3 Markdown Flavours

  • Markdown: The original Markdown syntax, developed by John Gruber.
  • CommonMark: A standardized and highly-specified variant of Markdown, intended to be more predictable and consistent across implementations.
  • GitHub Flavored Markdown: An extension of Markdown with additional features and syntax, used by GitHub for rendering Markdown in its platform.
  • GitLab Flavored Markdown: An extension of Markdown with additional features and syntax, used by GitLab for rendering Markdown in its platform.
  • Readme: A Markdown-based documentation format with support for features such as table of contents and automatic linking, used by many open-source projects.
  • Obsidian: A Markdown-based note-taking and organizing tool, with support for linking and organizing notes using graphs and diagrams.
Back to top