Parsing <sup> and <sub> tags #190

Closed
opened 2026-01-29 14:29:56 +00:00 by claunia · 8 comments
Owner

Originally created by @amkuchta on GitHub (Feb 13, 2018).

While these may not be specifically markdown, some markdown standards (looking at you, GitHub) do not provide emphasis extensions for super and subscript, which forces users to rely on <sup> and <sub> tags. Could MarkDig be updated to include support for this?

Originally created by @amkuchta on GitHub (Feb 13, 2018). While these may not be specifically markdown, some markdown standards (looking at you, GitHub) do not provide emphasis extensions for super and subscript, which forces users to rely on `<sup>` and `<sub>` tags. Could MarkDig be updated to include support for this?
claunia added the questionwontfix labels 2026-01-29 14:29:56 +00:00
Author
Owner

@xoofx commented on GitHub (Feb 13, 2018):

Could MarkDig be updated to include support for this?

Not sure to understand what markdig should include? Inline HTML are supported in markdig. Why markdig should have to parse sup/sub tags?

@xoofx commented on GitHub (Feb 13, 2018): > Could MarkDig be updated to include support for this? Not sure to understand what markdig should include? Inline HTML are supported in markdig. Why markdig should have to parse sup/sub tags?
Author
Owner

@amkuchta commented on GitHub (Feb 13, 2018):

@xoofx do I have to do anything special to get the inline parser to work?

@amkuchta commented on GitHub (Feb 13, 2018): @xoofx do I have to do anything special to get the inline parser to work?
Author
Owner

@xoofx commented on GitHub (Feb 13, 2018):

If the tags are correctly inside a paragraph/block line (and doesn't start it), afaik it works on almost any Markdown engine (Check babelmark)

@xoofx commented on GitHub (Feb 13, 2018): If the tags are correctly inside a paragraph/block line (and doesn't start it), afaik it works on almost any Markdown engine (Check [babelmark](https://babelmark.github.io/?text=This+is+x%3Csup%3E2%3C%2Fsup%3E))
Author
Owner

@amkuchta commented on GitHub (Feb 13, 2018):

If the tags are correctly inside a paragraph/block line (and doesn't start it)

This may be my issue - my superscript tags are are on the ending of one line and the beginning of another. Is there any way to update the library to allow for these items to be at the beginning / end of a line?

Markdown Snippet

* Security Content Automation Protocol (SCAP) content parsed via ACAS or the SCAP Compliance Checker (SCC)<sup>1</sup>
* Windows Automated Security Scanning Program (WASSP)  

---
<sup>1</sup>Parsing from additional sources is envisaged 
 
---
@amkuchta commented on GitHub (Feb 13, 2018): > If the tags are correctly inside a paragraph/block line (and doesn't start it) This may be my issue - my superscript tags are are on the ending of one line and the beginning of another. Is there any way to update the library to allow for these items to be at the beginning / end of a line? ## Markdown Snippet ```text * Security Content Automation Protocol (SCAP) content parsed via ACAS or the SCAP Compliance Checker (SCC)<sup>1</sup> * Windows Automated Security Scanning Program (WASSP) --- <sup>1</sup>Parsing from additional sources is envisaged --- ```
Author
Owner

@amkuchta commented on GitHub (Feb 13, 2018):

FYI, this is all in reference to https://github.com/Kryptos-FR/markdig.wpf/issues/10 (which you are tagged in)

@amkuchta commented on GitHub (Feb 13, 2018): FYI, this is all in reference to https://github.com/Kryptos-FR/markdig.wpf/issues/10 (which you are tagged in)
Author
Owner

@xoofx commented on GitHub (Feb 13, 2018):

errata, starting at the line is working as well (check this babelmark)

@xoofx commented on GitHub (Feb 13, 2018): errata, starting at the line is working as well (check this [babelmark](https://babelmark.github.io/?text=%3Csup%3E1%3C%2Fsup%3EParsing+from+**additional**+sources+is+envisaged))
Author
Owner

@amkuchta commented on GitHub (Feb 18, 2018):

Inline HTML are supported in markdig

For my own edification, with regards to the above quote, is inline HTML converted to markdown or left as HTML? Looking at the "rendered" markdown, my inline <sup> tags are not converted to markdown. According to @Kryptos-FR, he would rather not do any parsing of tags in MarkDig.WPF, but would rather relay solely on the output provided by MarkDig. Can MarkDig be updated to parse <sup> and <sub> tags to ^ and ~?

@amkuchta commented on GitHub (Feb 18, 2018): > Inline HTML are supported in markdig For my own edification, with regards to the above quote, is inline HTML converted to markdown or left as HTML? Looking at the "rendered" markdown, my inline `<sup>` tags are not converted to markdown. According to @Kryptos-FR, he would rather not do any parsing of tags in MarkDig.WPF, but would rather relay solely on the output provided by MarkDig. Can MarkDig be updated to parse `<sup>` and `<sub>` tags to `^` and `~`?
Author
Owner

@xoofx commented on GitHub (Feb 23, 2018):

Can MarkDig be updated to parse and tags to ^ and ~?

Not really fan of the idea. If you really need this, you can always try to develop and use your own extension.

@xoofx commented on GitHub (Feb 23, 2018): > Can MarkDig be updated to parse <sup> and <sub> tags to ^ and ~? Not really fan of the idea. If you really need this, you can always try to develop and use your own extension.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/markdig#190