Super-flavoured Markdown


Super-flavoured Markdown

syntax



Welcome to Super-flavoured Markdown, the best markdown syntax for note taking. Please read the following guidelines when typing up your own Supernote.

TITLES


TITLE OF A CHAPTER SUBSECTION

A chapter subsection corresponds to a group of lecture slides all covering the same larger topic. It is H3 (Heading 3).

### TITLE OF A CHAPTER SUBSECTION

TITLE OF A TOPIC

A topic usually corresponds to a slide of information and is H4 (Heading 4).

#### TITLE OF A TOPIC
TITLE OF A SUBTOPIC

A title of a subtopic is used only when a slide covers lots of different categorys and it is useful to split them up. i.e. The organelles of a cell. This the smallest title and is H5 (Heading 5)

##### TITLE OF A SUBTOPIC

Emphasis


Super-flavoured Markdown supports two types of emphasis: light and strong emphasis. Text parts that are surrounded with single asterisks * or underscores _ are treated as text with light emphasis, text parts surrounded with two asterisks or underscores are treated as text with strong emphasis. Surrounded means that the starting delimiter must not be followed by a space and that the stopping delimiter must not be preceded by a space.

Here is an example for text with light and strong emphasis:

*some text*
_some text_
**some text**
__some text__

The asterisk form is also allowed within a single word:

This is un*believe*able! This d_oe_s not work!

Text can be marked up with both light and strong emphasis, possibly using different delimiters. However, it is not possible to nest strong within strong or light within light emphasized text:

This is a ***text with light and strong emphasis***.
This **is _emphasized_ as well**.
This *does _not_ work*.
This **does __not__ work either**.

If one or two asterisks or underscores are surrounded by spaces, they are treated literally. If you want to force the literal meaning of an asterisk or an underscore you can backslash-escape it:

This is a * literal asterisk.
These are ** two literal asterisk.
As \*are\* these!

READER TIPS


Often you want some small writing offering a tip or suggestion to understand things better, this can be done by:

<small>I am a tip or small hint</small>

During sentences very important keywords are put in bold. And lesser keywords or important processes are put in italics.

Bullet point lists, should only contain a sentence or two, and in the don’t just list words (add some definitions):

  • Bullet Point One: I like cheese
  • Bullet Point Two: I think toast is better than cheese
  • Bullet Point Three: I disagree, beans on toast is best!

NOTE: Avoid using double bullet points as it looks bad on small phone screen!

It is not necessary to add full-stops to the end of bullet points. However if a bullet point exceeds two or three sentences/lines, cover them into separate H5 (Heading 5) with corresponding paragraphs for each point. i.e.

Bullet Point One

I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese. I like cheese.

Bullet Point Two

I think toast is better than cheese. I think toast is better than cheese. I think toast is better than cheese. I think toast is better than cheese. I think toast is better than cheese. I think toast is better than cheese. I think toast is better than cheese. I think toast is better than cheese.

Bullet Point Three

I disagree, beans on toast is best! I disagree, beans on toast is best! I disagree, beans on toast is best! I disagree, beans on toast is best! I disagree, beans on toast is best! I disagree, beans on toast is best! I disagree, beans on toast is best! I disagree, beans on toast is best!

Contrary to the above, avoid talking in the first and second person. Always try to write prose in third person as it sounds more professional.

Blockquotes


A blockquote is started using the > marker followed by an optional space and the content of the blockquote. The marker itself may be indented up to three spaces. All following lines, whether they are started with the blockquote marker or just contain text, belong to the blockquote because blockquotes support line wrapping.

The contents of a blockquote are block-level elements. This means that if you are just using text as content that it will be wrapped in a paragraph. For example, the following gives you one blockquote with two paragraphs in it:

> This is a blockquote.
>     on multiple lines
that may be lazy.
>
> This is the second paragraph.

Code Blocks


Moving on to code, all inline code, should be like this for. Even if it is just a word:

`for`

For multiple lines of code, or for a fancy box as above, instead of using one backtick, surround the code using three.

Images


Images can be specified via a syntax that is similar to the one used by links. The difference is that you have to use an exclamation mark before the first square bracket and that the link text of a normal link becomes the alternative text of the image link. As with normal links, image links can be written inline or reference style. For example:

Here comes a ![smiley](../images/smiley.png)! And here
![too](../images/other.png 'Title text'). Or ![here].
With empty alt text ![](see.jpg)

The link definition for images is exactly the same as the link definition for normal links. Since additional attributes can be added via span and block IALs, it is possible, for example, to specify image width and height:

Here is an inline ![smiley](smiley.png){:height="36px" width="36px"}.

And here is a referenced ![smile]

[smile]: smile.png
{: height="36px" width="36px"}

Maths


Whenever you use maths equations/symbols in a markdown file, a separate language called LaTeX is used. This is decoded by Supernotes when you upload it to the website.

For inline formulas like this $ E = mc^2 $ wrap the code in a single $ symbol:

$ E = mc^2 $

For multiple line formulas or for the pretty grey box use two dollar symbols. Here are a few really useful points:

  1. For inline formulas, enclose the formula in $...$. For displayed formulas, use $$...$$.
    These render differently. For example, type
    $\sum_{i=0}^n i^2 = \frac{(n^2+n)(2n+1)}{6}$
    to show $\sum_{i=0}^n i^2 = \frac{(n^2+n)(2n+1)}{6}$ (which is inline mode) or type
    $$\sum_{i=0}^n i^2 = \frac{(n^2+n)(2n+1)}{6}$$
    to show (which is display mode).

  2. For Greek letters, use \alpha, \beta, …, \omega: $\alpha, \beta, … \omega$. For uppercase, use \Gamma, \Delta, …, \Omega: $\Gamma, \Delta, …, \Omega$.

  3. For superscripts and subscripts, use ^ and _. For example, x_i^2: $x_i^2$, \log_2 x: $\log_2 x$.

  4. Groups. Superscripts, subscripts, and other operations apply only to the next “group”. A “group” is either a single symbol, or any formula surrounded by curly braces {}. If you do 10^10, you will get a surprise: $10^10$. But 10^{10} gives what you probably wanted: $10^{10}$. Use curly braces to delimit a formula to which a superscript or subscript applies: x^5^6 is an error; {x^y}^z is ${x^y}^z$, and x^{y^z} is $x^{y^z}$. Observe the difference between x_i^2 $x_i^2$ and x_{i^2} $x_{i^2}$.

  5. Parentheses Ordinary symbols ()[] make parentheses and brackets $(2+3)[4+4]$. Use \{ and \} for curly braces ${}$.

    These do not scale with the formula in between, so if you write (\frac{\sqrt x}{y^3}) the parentheses will be too small: $(\frac{\sqrt x}{y^3})$. Using \left(\right) will make the sizes adjust automatically to the formula they enclose: \left(\frac{\sqrt x}{y^3}\right) is $\left(\frac{\sqrt x}{y^3}\right)$.

    \left and\right apply to all the following sorts of parentheses: ( and ) $(x)$, [ and ] $[x]$, \{ and \} ${ x }$, | $ x $, \vert $\vert x \vert$, \Vert $\Vert x \Vert$, \langle and \rangle $\langle x \rangle$, \lceil and \rceil $\lceil x \rceil$, and \lfloor and \rfloor $\lfloor x \rfloor$. There are also invisible parentheses, denoted by .: \left.\frac12\right\rbrace is $\left.\frac12\right\rbrace$.
  6. Sums and integrals \sum and \int; the subscript is the lower limit and the superscript is the upper limit, so for example \sum_1^n $\sum_1^n$. Don’t forget {} if the limits are more than a single symbol. For example, \sum_{i=0}^\infty i^2 is $\sum_{i=0}^\infty i^2$. Similarly, \prod $\prod$, \int $\int$, \bigcup $\bigcup$, \bigcap $\bigcap$, \iint $\iint$.

  7. Fractions There are two ways to make these. \frac ab applies to the next two groups, and produces $\frac ab$; for more complicated numerators and denominators use {}: \frac{a+1}{b+1} is $\frac{a+1}{b+1}$. If the numerator and denominator are complicated, you may prefer \over, which splits up the group that it is in: {a+1\over b+1} is ${a+1\over b+1}$.

  8. Radical signs Use sqrt, which adjusts to the size of its argument: \sqrt{x^3} $\sqrt{x^3}$; \sqrt[3]{\frac xy} $\sqrt[3]{\frac xy}$. For complicated expressions, consider using {...}^{1/2} instead.

  9. Some special functions such as “lim”, “sin”, “max”, “ln”, and so on are normally set in roman font instead of italic font. Use \lim, \sin, etc. to make these: \sin x $\sin x$, not sin x $sin x$. Use subscripts to attach a notation to \lim: \lim_{x\to 0}

  10. There are a very large number of special symbols and notations, too many to list here; see this shorter listing, or this exhaustive listing. Some of the most common include:
    • \lt \gt \le \ge \neq $\lt\, \gt\, \le\, \ge\, \neq$. You can use \not to put a slash through almost anything: \not\lt $\not\lt$ but it often looks bad.
    • \times \div \pm \mp $\times\, \div\, \pm\, \mp$. \cdot is a centered dot: $x\cdot y$
    • \cup \cap \setminus \subset \subseteq \subsetneq \supset \in \notin \emptyset \varnothing $\cup\, \cap\, \setminus\, \subset\, \subseteq \,\subsetneq \,\supset\, \in\, \notin\, \emptyset\, \varnothing$
    • {n+1 \choose 2k} or \binom{n+1}{2k} ${n+1 \choose 2k}$
    • \to \rightarrow \leftarrow \Rightarrow \Leftarrow \mapsto $\to\, \rightarrow\, \leftarrow\, \Rightarrow\, \Leftarrow\, \mapsto$
    • \land \lor \lnot \forall \exists \top \bot \vdash \vDash $\land\, \lor\, \lnot\, \forall\, \exists\, \top\, \bot\, \vdash\, \vDash$
    • \star \ast \oplus \circ \bullet $\star\, \ast\, \oplus\, \circ\, \bullet$
    • \approx \sim \simeq \cong \equiv \prec \lhd $\approx\, \sim \, \simeq\, \cong\, \equiv\, \prec, \lhd$.
    • \infty \aleph_0 $\infty\, \aleph_0$ \nabla \partial $\nabla\, \partial$ \Im \Re $\Im\, \Re$
    • For modular equivalence, use \pmod like this: a\equiv b\pmod n $a\equiv b\pmod n$.
    • \ldots is the dots in $a_1, a_2, \ldots ,a_n$ \cdots is the dots in $a_1+a_2+\cdots+a_n$
    • Some Greek letters have variant forms: \epsilon \varepsilon $\epsilon\, \varepsilon$, \phi \varphi $\phi\, \varphi$, and others. Script lowercase l is \ell $\ell$.
  11. Spaces MathJax usually decides for itself how to space formulas, using a complex set of rules. Putting extra literal spaces into formulas will not change the amount of space MathJax puts in: a␣b and a␣␣␣␣b are both $a b$. To add more space, use \, for a thin space $a\,b$; \; for a wider space $a\;b$. \quad and \qquad are large spaces: $a\quad b$, $a\qquad b$. To set plain text, use \text{…}: ${x\in s\mid x\text{ is extra large}}$. You can nest $…$ inside of \text{…}.

  12. Accents and diacritical marks Use \hat for a single symbol $\hat x$, \widehat for a larger formula $\widehat{xy}$. If you make it too wide, it will look silly. Similarly, there are \bar $\bar x$ and \overline $\overline{xyz}$, and \vec $\vec x$ and \overrightarrow $\overrightarrow{xy}$ and \overleftrightarrow $\overleftrightarrow{xy}$. For dots, as in $\frac d{dx}x\dot x = \dot x^2 + x\ddot x$, use \dot and \ddot.

  13. Special characters used for MathJax interpreting can be escaped using the \ character: \$ $$$, \{ ${$, \_ $_$, etc. If you want \ itself, you should use \backslash $\backslash$, because \\ is for a new line.

For more help on writing LaTeX the following is a very useful guide:

LaTeX Maths Syntax Guide

Tables


Now with the fickle problem of tables. Use them, but don’t have more than three/four columns otherwise mobile devices struggle to view them properly.

Tables can be created with or without a leading pipe character: If the first line of a table contains a pipe character at the start of the line (optionally indented up to three spaces), then all leading pipe characters (i.e. pipe characters that are only preceded by whitespace) are ignored on all table lines. Otherwise they are not ignored and count when dividing a table line into table cells.

There are four different line types that can be used in a table:

  • Table rows define the content of a table.

    A table row is any line that contains at least one pipe character and is not identified as any other type of table line! The table row is divided into individual table cells by pipe characters. An optional trailing pipe character is ignored. Note that literal pipe characters need to be escaped except if they occur in code spans or HTML <code> elements!

    Header rows, footer rows and normal rows are all done using these table rows. Table cells can only contain a single line of text, no multi-line text is supported. The text of a table cell is parsed as span-level elements.

    Here are some example table rows:

    | First cell|Second cell|Third cell
    | First | Second | Third |
    
    First | Second | | Fourth |
    
  • Separator lines are used to split the table body into multiple body parts.

    A separator line is any line that contains only pipes, dashes, pluses, colons and spaces/tabs and which contains at least one dash and one pipe character. The pipe and plus characters can be used to visually separate columns although this is not needed. Multiple separator lines after another are treated as one separator line.

    Here are some example separator lines:

    |----+----|
    +----|----+
    |---------|
    |-
    | :-----: |
    -|-
    
  • The first separator line after at least one table row is treated specially, namely as header separator line. It is used to demarcate header rows from normal table rows and/or to set column alignments. All table rows above the header separator line are considered to be header rows.

    The header separator line can be specially formatted to contain column alignment definitions: An alignment definition consists of an optional space/tab followed by an optional colon, one or more dashes, an optional colon and another optional space/tab. The colons of an alignment definition are used to set the alignment of a column: if there are no colons, the column uses the default alignment, if there is a colon only before the dashes, the column is left aligned, if there are colons before and after the dashes, the column is center aligned and if there is only a colon after the dashes, the column is right aligned. Each alignment definition sets the alignment for one column, the first alignment definition for the first column, the second alignment definition for the second column and so on.

    Here are some example header separator lines with alignment definitions:

    |---+---+---|
    + :-: |:------| ---:|
    | :-: :- -: -
    :-: | :-
    
  • A footer separator line is used to demarcate footer rows from normal table rows. All table rows below the footer separator line are considered to be footer rows.

    A footer separator line is like a normal separator line except that dashes are replaced by equal signs. A footer separator line may only appear once in a table. If multiple footer separator lines are used in one table, only the last is treated as footer separator line, all others are treated as normal separator lines. Normal separator lines that are used after the footer separator line are ignored.

    Here are some example footer separator lines:

    |====+====|
    +====|====+
    |=========|
    |=
    

Trailing spaces or tabs are ignored in all cases. To simplify table creation and maintenance, header, footer and normal separator lines need not specify the same number of columns as table rows; even |- and |= are a valid separators.

Given the above components, a table is specified by

  • an optional separator line,
  • optionally followed by zero, one or more table rows followed by a header separator line,
  • one or more table rows, optionally interspersed with separator lines,
  • optionally followed by a footer separator line and zero, one or more table rows and
  • an optional trailing separator line.

Also note

  • that the first line of a table must not have more than three spaces of indentation before the first non-space character,
  • that each line of a table needs to have at least one not escaped pipe character so that Super-flavoured Markdown recognizes it as a line belonging to the table and
  • that tables have to start and end on block boundaries

Important things to note are that:

  • tables do not need to have a table header.
  • tables can be structured using separator lines.
  • tables can contain a table footer.
  • tables need to be separated from other block-level elements.

Here is an example for a table with a table header row, two table bodies and a table footer row:

|-----------------+------------+-----------------+----------------|
| Default aligned |Left aligned| Center aligned  | Right aligned  |
|-----------------|:-----------|:---------------:|---------------:|
| First body part |Second cell | Third cell      | fourth cell    |
| Second line     |foo         | **strong**      | baz            |
| Third line      |quux        | baz             | bar            |
|-----------------+------------+-----------------+----------------|
| Second body     |            |                 |                |
| 2 line          |            |                 |                |
|=================+============+=================+================|
| Footer row      |            |                 |                |
|-----------------+------------+-----------------+----------------|

The above example table is rather time-consuming to create without the help of an ASCII table editor. However, the table syntax is flexible and the above table could also be written like this:

|---
| Default aligned | Left aligned | Center aligned | Right aligned
|-|:-|:-:|-:
| First body part | Second cell | Third cell | fourth cell
| Second line |foo | **strong** | baz
| Third line |quux | baz | bar
|---
| Second body
| 2 line
|===
| Footer row

Export to Supernotes


That’s it for now. When you export your markdown, make sure you include the following at the beginning of the file, and the filename has the following format with the following name date-subject-chapter-num.markdown:

---
layout: post
num: 101
title: Super-flavoured Markdown
date: 2017-03-08 00:10:45
tags: syntax
author: Tobias Whetton
color: e21345
icon: fa-question-circle
---

Have fun note-taking!

©  Super-Flavoured Markdown - built upon the Kramdown Markdown format with built in LaTeX support


return  link
Written by Tobias Whetton