4 ms·
I like the idea of participating, but when I made my little Hugo-based blog I also liked the idea of presenting equations. Is there any way to do that without M
by dcuthbertson 2y ago
I like the idea of participating, but when I made my little Hugo-based blog I also liked the idea of presenting equations. Is there any way to do that without MathJax, KaTeX, or similar libraries?
- paulryanrogers 2y agoAre `<img>`, SVG, and fonts not enough?
- dcuthbertson 2y agoThanks, but I have no idea. I never tried generating SVG from LaTeX. Others suggested MathML, some tools, and OpenType math fonts, so I'm going to try that route first.
- bpfrh 2y agoWhat about exporting to mathml? https://developer.mozilla.org/en-US/docs/Web/MathML https://developer.mozilla.org/en-US/docs/Web/MathML
- persnickety 2y agoMathML seems to be forgotten. I don't recommend writing it by hand, but you don't need any JS to present it.
- cjs_ac 2y agoIf you use a font that supports OpenType maths, you can just put MathML in your HTML and modern browsers will render it. MathML can be generated from LaTeX with pandoc or latexml.
- dcuthbertson 2y agoThanks folks. Your replies are very helpful. I'll take a look at MathML, pandoc, and LaTeXML. Writing MathML from scratch looks tedious, but pandoc and/or LaTeXML might be just the thing to make a conversion easy.
- jwmerrill 2y agoKaTeX supports server side rendering to an html string. If you do this, the client only needs to load the css component of katex, and not the js component. I believe MathJax has a similar capability.