[kramdown-users] kramdown syntax: strikeout, subscripts and superscripts
t_leitner at gmx.at
Thu Jan 20 15:27:07 EST 2011
On 2011-01-20 16:13 +0100 Alex Wall wrote:
> I think it would be nice if kramdown could also create strikeout,
> subscripts and superscripts.
> For compatibility reasons I would be the good to have the same syntax
> as pandoc has.
> H~2~O is a liquid.
> 2^10^ is 1024.
> This ~~is deleted text.~~
Since all three suggested syntaxes use characters currently not used by
kramdown, it would be okay for me to include them in kramdown. So, let's
start the discussion what the exact syntax would be like:
Text parts surrounded by tilde characters are treated as subscript
text. If the text part contains a whitespace character (space, tab,
newline), it has to be escaped. Nesting of subscript text parts is
not possible. Here are some examples:
This is the formula for water: H~2~O.
Another thing: P~w\ and\ v~ = 42
Like subscript, but with the caret instead of the tilde
Like strong emphasis with asterisk
So: any opinions on (not) including the syntax?
More information about the kramdown-users