Meta-request: mediawiki Math parity
See original GitHub issueIs your feature request related to a problem? Please describe. I am trying to use KaTeX on Wikipedia for fun. They have kicked away MathJax because of the server load and the speed issues, but I figured a KaTeX userscript won’t hurt. After all, what’s not to love about having actual text rendered instead of some SVG or even PNG image?
Describe the solution you’d like: KaTeX should add support for everything TeX mentioned in the current Wikipedia formula help page. The errors are:
KaTeX parse error: Limit controls must follow a math operator at position 58: …ratorname {sn} \̲l̲i̲m̲i̲t̲s̲ ̲_{b>c}(b+c)
KaTeX parse error: Undefined control sequence: \S at position 63: …Re ,\circledS ,\̲S̲ ̲,\P ,\mathrm {\…
KaTeX parse error: Undefined control sequence: \P at position 9: \amalg \̲P̲ ̲\S \%\dagger \d…
KaTeX parse error: Undefined control sequence: \sideset at position 2: \̲s̲i̲d̲e̲s̲e̲t̲ ̲{_{1}^{2}}{_{3}…
KaTeX parse error: Undefined control sequence: \iiiint at position 2: \̲i̲i̲i̲i̲n̲t̲ ̲\limits _{F}dx\…
KaTeX parse error: Undefined control sequence: \definecolor at position 2: \̲d̲e̲f̲i̲n̲e̲c̲o̲l̲o̲r̲ ̲{myorange}{rgb}…
In addition, a good bunch of the colors at the Colors section are falling back to black. Wait, are you just passing the names directly to HTML? That’s cheeky but surprisingly effective.
Link to or name of a (La)TeX package that provides the same feature:
- I have no idea what the \limits devil is. They are probably doing it wrong.
- \S and \P in math mode are base LaTeX2e, I think. They can be mapped to unicode chars.
- \sideset is from amsmath.
- \iiiint from esint is covered in #2059.
- \definecolor from xcolor is covered in #750.
- Additional colors are invoked from xcolor, but probably part of dvips. Still sort of the same lookup-table requirement from 750.
Describe alternatives you’ve considered: Changing the existing formulae is unfortunately not acceptable. I mean, since it’s just for fun, I can choose to not play.
Additional context: Add any other context or screenshots about the feature request here.
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (8 by maintainers)

Top Related StackOverflow Question
I just found out another cool thing about KaTeX: the HTML output allows line wrap between
.baseunits!The definition for sideset looks fine on the playground. Maybe it’s good to be added?