website guide
Formatting Text with Markdown
09 Jun 2023Contents
Text is formatted using a simple syntax called Markdown.1 You can also format your text with HTML, but I recommend starting with Markdown.
Simple text formatting
To italicize text, surround the text with one asterisk or underscore:
This _sentence_ contains *italicized* text.
==> This sentence contains italicized text.
To create bold text, surround the text with two asterisks or underscores:
This __sentence__ contains **bold** text.
==> This sentence contains bold text.
To create bold and italicized text, surround the text with three asterisks or underscores:
This ___sentence___ contains ***bold and italic*** text.
==> This sentence contains bold and italic text.
Smart formatting
Jekyll converts characters to smart punctuation.
- All "straight quotes" will be converted to “smart quotes”
- Two hyphen characters will convert to an en dash, which can also be typed directly with Option-dash. Use this when listing a range of times or dates:
Ludwig van Beethoven (1770--1827)
==> Ludwig van Beethoven (1770–1827)
- Three hyphen characters will convert to an em dash, which can also be typed directly with Option-Shift-dash. Use this for emphasis.
The grocery list had two items---butter and bread.
==> The grocery list had two items—butter and bread.
Typography tips
- Hyphens: “-“ (dash key) is for words. “–” (en dash, Option-dash) is for date ranges and used throughout the project pages. “—” (em dash, Option-Shift-dash) is for text. See CV for best examples.
Whitespace breaks
Sometimes within a paragraph a line will break between two words that looks odd or ugly. Examples: “Part 3”, “Boston, MA”. You can avoid have a line break in between those words by using a non-breaking space in place of a normal space. To do this use the HTML non-breaking space
:
Boston, MA
==> Boston, MA
Don’t forget the semicolon at the end of
.
Headers
You can add section headers by adding between 1 and 6 hash marks (#). Personally I rarely go beyond 4. We may need to discuss how headers at a certain section level are formatted.
# Header at the first level
## Header at the second level
### Header at the third level
#### Header at the fourth level
Header at the first level
Header at the second level
Header at the third level
Header at the fourth level
Lists
Add an unordered list by add a dash, asterisk, or plus in front of every line in the list.
- Item 1, using a dash
- Item 2
- Item 3
* Item 1, using an asterisk
* Item 2
* Item 3
+ Item 1, using a plus
+ Item 2
+ Item 3
- Item 1, using a dash
- Item 2
- Item 3
- Item 1, using an asterisk
- Item 2
- Item 3
- Item 1, using a plus
- Item 2
- Item 3
Add an ordered list by listing every line with a number and a period. Notice in the example below that the numbers do not need to be listed consecutively or uniquely for them to be listed in the correct order.
1. Item 1
2. Item 2
5. Item 3
5. Item 4
- Item 1
- Item 2
- Item 3
- Item 4
If you want a list to start with a specific number, specify it at the end of the list.
1. Item 1, but we want to start at 3
2. Item 2
5. Item 3
{: start="3"}
- Item 1, but we want to start at 3
- Item 2
- Item 3
Add sub-lists by indenting them. You can mix and match sub-lists.
- Item A
- Item B
1. Item 1
2. Item 2
- Item C
- Item A
- Item B
- Item 1
- Item 2
- Item C
If you want to add another paragraph within a list item, indent the paragraph and make sure there is a blank link on either side.
* This is the first list item.
* Here's the second list item.
And here's another paragraph below the second list item.
* And here's the third list item.
- This is the first list item.
-
Here’s the second list item.
And here’s another paragraph below the second list item.
- And here’s the third list item.
Spell-checking
Sublime Text can spell-check as you type.
Normally it’s a feature that you need to turn on per file. Go to Sublime Text > View > Spell Check (fn-F6).
You can turn it on by default, by adding it to your preferences.
- Go to Sublime Text > Settings… > Settings (Command-,)
- A new window should appear with all of the possible settings available for you on the left panel, and your settings on the right panel.
- Add to the right panel:
"spell_check": true,
- Save the file. The setting is immediately turned on.
You can turn off the setting by default by switching the preference to false
or removing that line altogether.