Open dumblob opened 9 years ago
Indeed, it seems that marked.js
does not follow Markdown "rules". For example, it will apply markup to Markdown blocks inside literal HTML blocks. Like in this:
import Markdown
main =
Markdown.toHtml markdown
markdown = """
<div>
<p>Codes are "p_2014__"* for balance sheet and "p_2014_2000_"** for income statement.
....Notes: *as of year end, **span of 14 years.</p></div>
"""
Also consider: https://github.com/chjj/marked/issues/236#issuecomment-23221556
And it seems a bit unclear whether marked.js
is still being maintained: https://github.com/chjj/marked/issues/724
Would it be possible to switch to a well-defined "flavour" of the original Markdown called CommonMark? There are very good JS implementations and I'd recommend markdown-it.
CommonMark continues in the spirit of well-defined typing (which is one of the greatest advantages of Elm) and brings it to the domain of syntax.