Closed billstclair closed 7 years ago
I looked at the evancz/elm-markdown package, in the hopes that I could just change its output, but it is a thin wrapper around the Virtual DOM JavaScript code.
I made new enhancement tickets to replace the bits of Markdown I decided not to do at this time.
Nothing left to do here. Closed.
I've been way too fast and loose with the #md syntax. Make it more compatible with:
https://daringfireball.net/projects/markdown/syntax
When I'm done here, the implementation should match [Markdown.md (../blob/master/Markdown.md).
TODO
The reference style of specifying URLs separate from their uses would also be nice, but is not high priority.
Done
Need to devise some way to specify the classes of all the Html elements created by Markdown expansion.
Class specifications can come before the top-level types, e.g. table, list, blockquote, preformat.
Entities. At least
and©
. Also numeric entities, e.g.0
and0
both represent "0".Automatic links surrounded as \http://example.com and \user@host.com would be nice. I will NOT pattern match on URLs.
Horizontal rules should be easy. Add them.
Tables would be nice, as done by GitHub.
Blockquotes.
In particular, use backslash for escaping, not doubling the characters.
Some way of escaping JSON, perhaps double square brackets:
Headers: #, ##, ###, etc. at the beginning of the line.
Do NOT support underlines under a header. Do matching #s at end of header line, if it's easy. (it was easy, so I did it)
Add (optional) titles to links and images:
_foo_
or*foo*
becomes foo [=done=]__foo__
or**foo**
becomes foo [=done=]A leading
*
or_
does nothing if followed by whitespace. [=done=] A trailing*
or_
does nothing if preceded by whitespace. [=done=]I've always hated having to double the characters to get bold, but that's the spec. [=done=]
Double-newline must convert to paragraph tags of the paragraphs before and after. [=done=]
" \n"
, newline preceded by at least two spaces, is<br/>
. Do I need to support<br>
,<br/>
, and<br />
as well? It'd rather not. Github doesn't require the preceding spaces. That's what I'm doing now. I'm going to change it to Gruber's way, requiring two or more spaces before a newline to generate a line-break. This is more natural for non-programmers. [=done=]Need to implement multiple backtick for codeblocks. Probably do NOT need to implement 4-space indent for codeblocks, though real markup converts the latter to
<pre><code>...</code></pre>
and the former to<code>...</code>
. I think I'll just wrap<pre>...</pre>
around any multi-line code block. Also need to use<pre>...</pre>
INSTEAD of<p>...</p>
. [=done=]Need lists, and nested lists. [=done=]