Template for a Post article
You need this knowledge to avoid being stranded on the road
And introductory paragraph goes here, without a title. If the more comment if used, the text above the more is used as a summary, and any summary tag in the frot matter is ignored.
Text below the more will not be included in the summary.
Markdown in Hugo
Introduction
This article is a reference for Hugo’s version of markdown as well as Hugo’s processing. Here are a few good Markdown references and tutorials:
General markdown references:
- Markdown Guide
- Wikipedia Markdown entry
- CommonMark - the markdown “standard”
All about Hugo’s markdown:
- Goldmark - Goldmark is a markdown processor written in go, which is used by Hugo
- Configuring Hugo’s markdown - specific information on configuring Goldmark, and what Goldmark features Hugo supports.
- Image Processing
- Shortcodes
- Links and Cross References
- Markdown Attributes - add HTML attributes when rendering HTML
- Syntax Hightlighting
- Diagrams
- Mathematics - Note that many themes implement their own support. Mainroad does.
- Emoji Support. Set
enableEmoji
totrue
in the main site configuration. For a list of emoji see Emoji Cheat Sheet
Headings (Heading 1)
start here
Heading 2
next paragraph
Heading 3
next paragraph
Heading 4
next paragraph
Heading 5
next paragraph
Heading 6
and we are done!
List Types
Unordered list:
- First item
- Second item
- Third item
- Last item
Ordered List:
- First item
- Second item
- Third item
- Last item
Definition List Markdown Extra:
- Apple
- Pomaceous fruit of plants of the genus Malus in the family Rosaceae.
- Also a computer company
- Orange
- The fruit of an evergreen tree of the genus Citrus.
- Peanut
- Actually a legume, not a nut at all!
Task List GitHub Flavored Markdown:
- Foo to do
- Baz to do
- Baz is done
Lists can be nested:
- Item 1
- Item 2
- Another iten
- another item
- sub-item 1
- sub item 2
- sub item 3
- final item
Blockquotes
Blockquotes can have a title
This is a simple blockquote.
Block quotes can be nested
Basic admonitions:
[!NOTE] Useful information that users should know, even when skimming content.
[!TIP] Helpful advice for doing things better or more easily.
[!IMPORTANT] Key information users need to know to achieve their goal.
[!WARNING] Urgent info that needs immediate user attention to avoid problems.
[!CAUTION] Advises about risks or negative outcomes of certain actions.
Tables
Code
Math
Inline Elements
Emoji
Use the site configuration enableEmoji = true
to enable emoji. Look on the web for emoji definitions, for example Emojipedia Emoji Cheatsheet. Here are a few examples:
Symbol | Emoji |
---|---|
:smile: | 😄 |
:cry: | 😢 |
:mask: | 😷 |
:poop: | 💩 |
:thumbsup: | 👍 |
:smiley_cat: | 😺 |
Unicode Characters
Since browsers, html, and most tools are now UTF-8 compliant, using UTF-8 characters “just works”. Use a Unicode Character Table to search for your desired character and paste it into your markdown file. Some examples:
Unicode | UTF-8 | Result | Name of Character |
---|---|---|---|
U+2318 | E2 8C 98 | ⌘ | PLACE OF INTEREST SIGN |
U+2325 | E2 8C A5 | ⌥ | OPTION KEY |
U+21E7 | E2 87 A7 | ⇧ | UPWARDS WHITE ARROW (Shift) |
U+21EA | E2 87 AA | ⇪ | UPWARDS WHITE ARROW FROM BAR (Caps Lock) |
U+2303 | E2 8C 83 | ⌃ | UP ARROWHEAD (Ctrl) |
U+232B | E2 8C AB | ⌫ | ERASE TO THE LEFT (Delete) |
U+F8FF | EF A3 BF | | Apple Symbol |
U+21A9 | E2 86 A9 | ↩ | LEFTWARDS ARROW WITH HOOK (Return) |
U+00AE | C2 AE | ® | REGISTERED SIGN |
U+00A9 | C2 A9 | © | COPYRIGHT SIGN |
U+2122 | E2 84 A2 | ™ | TRADE MARK SIGN |
U+2103 | E2 84 83 | ℃ | DEGREE CELSIUS |
U+2109 | E2 84 89 | ℉ | DEGREE FAHRENHEIT |