Markdown Examples
This post is a showcase of how to write Markdown, featuring various examples of the elements you can create. Open this post in a text editor so you can see exactly how they've been added.
Additionally, I also recommend reading a Markdown guide like this one, or at least having it handy, so you can consult it when necessary.
Headings (this is level 1)
Heading level 2
Heading level 3
Heading level 4
Heading level 5
Heading level 6
Paragraphs
Strawberries are sweet and yummy, but so are some other things:
Halvah oat cake fruitcake dessert chocolate cake. Croissant cake marshmallow bonbon shortbread candy canes dragée chocolate caramels. Toffee toffee wafer croissant chocolate cake sugar plum liquorice apple pie. Cupcake lemon drops sweet pie cake brownie. Tart brownie biscuit danish sweet roll. Sugar plum cake donut toffee caramels bear claw jujubes. Cake halvah toffee bear claw jelly beans. Toffee jelly beans gingerbread brownie sesame snaps chocolate cake brownie danish biscuit. Sweet cupcake sweet roll powder muffin.
Fruitcake dessert marshmallow cake oat cake caramels jelly. Cake marshmallow carrot cake fruitcake muffin gingerbread tootsie roll sugar plum. Bonbon pudding wafer powder halvah lollipop dessert. Jelly-o chocolate bar cake topping cotton candy cotton candy halvah powder.
If you want line breaks
Just add two spaces
At the end of your sentence
Strong Text and Emphasis
You can use double asterisks for strong text, and single asterisks for emphasis.
Those will usually show up as bold and italics, but themes/custom styling can override that!
You can also use triple asterisks for both of them.
Blockquotes
This is a blockquote!
Blockquotes are quite neat
You can do many things with them.
- As you can see, you can put other elements inside them.
They sure are a lot of fun.
Lists
Names for "Strawberry" in a few languages:
- "morango"
- "fresa"
- "fraise"
- "jagoda"
- This is also a list
- However
- It's unordered
- I think it's still cool
- Don't you agree?
- You can also use an asterisk.
- If you prefer.
- You can even mix the two!
Code Blocks
If you need to code
, you can use backticks
.
# you can also create fenced code blocks
# for multiline stuff
if (strawberry) {
console.log('yum!');
};
Links
To create a link, like, for example, one to my site, just use square brackets for the text, and round brackets for the URL.
Images
Images are fundamental to any blog, right?
It's similar to the link syntax, except the square brackets are for alt text, and the round brackets are for the file path. Also, don't forget the exclamation mark!
HTML
Finally, when Markdown just doesn't cut it, you CAN write HTML, if you really want to. Any valid HTML is also valid Markdown.
You probably don't want to write HTML! But it does mean you can paste things in your posts like, for example, Youtube embeds!
That's it for this post! There's more you can do, but I think this covers most use cases. Be sure to read a full Markdown guide!