vscode-markdown-pdf icon indicating copy to clipboard operation
vscode-markdown-pdf copied to clipboard

PDF export cannot recognize the Math symbols grammar

Open HikaraX99 opened this issue 11 months ago • 4 comments

Math grammar works well on my markdown preview, however, the PDF export cannot recognize math grammar. Hopefully, this issue can be fixed. By the way, thanks for your effort on this project.

Current output: Image

Correct one: Image

HikaraX99 avatar Jan 22 '25 06:01 HikaraX99

same issue +1

gaolinbo avatar Feb 25 '25 17:02 gaolinbo

+1 anyone is aware of a extension which works with math grammar too?

ojasiiitd avatar Feb 27 '25 11:02 ojasiiitd

I've found a solution on this thread.

You just need to copy the code below at the beginning of the MarkDown file, and then the extension MarkDown PDF should recognize and convert the math symbol.

<script type="text/javascript" 
  src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({ tex2jax: {inlineMath: [['$', '$']]}, messageStyle: "none" });
</script>  

MrAleFonta avatar Mar 11 '25 11:03 MrAleFonta

I've found a solution on this thread.

You just need to copy the code below at the beginning of the MarkDown file, and then the extension MarkDown PDF should recognize and convert the math symbol.

Thanks, this works with pdf export but breaks markdown rendering in GitHub :(

htjain avatar Apr 24 '25 10:04 htjain