Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Markdown: add ability to not escape html characters in markdown #35523

Closed
Hugo-Trentesaux opened this issue Apr 19, 2020 · 3 comments
Closed

Comments

@Hugo-Trentesaux
Copy link

Currently, when exporting markdown to html, all html special characters are escaped:

using Markdown
a = Markdown.parse("This is *important* text with <i>html</i> in it");
# parsed as
Markdown.Paragraph(Any["This is ", Markdown.Italic(Any["important"]), " text with <i>html</i> in it"])
# then exporting to html
Markdown.html(a)
# output below
"<p>This is <em>important</em> text with &lt;i&gt;html&lt;/i&gt; in it</p>\n"

and there is no way of getting such an output:

<p>This is <em>important</em> text with <i>html</i> in it</p>

So, this issue is a feature request.

It could even be the default behavior for all markdown blocks except code block.

(similar to #34042)

@fredrikekre
Copy link
Member

Duplicate of #17837 (It is escaped since the parser doesn't know this is HTML and thus has to escape it.)

@KDr2
Copy link
Contributor

KDr2 commented Apr 20, 2020

I also request a new feature of Markdown here: Comment Support.

It was discussed recently here: https://discourse.julialang.org/t/does-markdown-support-comments/37607

If we have a way to not escape HTML tags as it is proposed in this issue, I think we can use <!-- --> as comments then?

@stevengj
Copy link
Member

stevengj commented May 7, 2020

Closing as a duplicate.

@stevengj stevengj closed this as completed May 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants