You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There seems to be a problem when rendering math blocks which contains equal signs (=) on a single line. It seems to interpret this as a heading (this is done by the lheading parse rule in markdown-it), screwing up the entire rendering of the output.
I did some further investigation into this issue. It seems like you can prevent something from being rendered as a lheading by registering as an alt for the paragraph rule. If you indicate that a block can be rendered by your rule it skips that block from being rendered as a heading. However, it seems like block rules have different parameters, so simply using the existing functions math or texMath won't work.
It seems that markdown-it-math doesn't have this issue, using the exact technique as described above. See here.
So it seems that fixing this shouldn't be too hard, however as I have zero experience writing markdown-it plugins the way to do this seems quite hard for now.
There seems to be a problem when rendering math blocks which contains equal signs (
=
) on a single line. It seems to interpret this as a heading (this is done by thelheading
parse rule in markdown-it), screwing up the entire rendering of the output.Example input which shows this behavior:
Disabling the
lheading
rule in block (md.block.ruler.disable(['lheading'])
) fixes the issue, but this breaks al headings of this kind (as expected).The text was updated successfully, but these errors were encountered: