News for hackers. Stuff that matters.
Re:KaTeX – The fastest math typesetting library for the web by joppy on Sunday October 11, 2020 @06:18AM (#24744822)
The thing specifically with KaTeX is that if you do this, you can blow page sizes out completely. In the example above, less than 20 characters of latex turned into a giant amount of HTML markup. Repeat this in many places for a mathematics-heavy page, and the browser might be better off just running KaTeX itself. Besides, you need to ship a whole bunch of fonts and a stylesheet anyway.
Re:KaTeX – The fastest math typesetting library for the web by mbeex on Sunday October 11, 2020 @10:24AM (#24746007)
KaTeX has an 'output' option and one of his settings is 'mathml'. You can produce clean MathML this way and even mixed HTML/MathML output (default and what you see in the OP's example) with MathML for accessibility. Problem with the pure approach isn't KaTeX but the browser support.
Re:KaTeX – The fastest math typesetting library for the web by franga2000 on Sunday October 11, 2020 @08:14AM (#24745268)
Oh yeah, definitely, I was just responding to the "calling server-side JS" part. Even if the same library was implemented in native code, you still wouldn't want to be calling it inline from a cgi* script.