It fails with:
Uncaught ReferenceError: MathJax is not defined.
message: Uncaught ReferenceError: MathJax is not defined
fileName: https://jsperf.com/katex-vs-mathjax
lineNumber: 129
Just bumped into this as well. The problem is this code in the speed test:
<link href="http://xymostech.com/katex/katex.min.css" rel="stylesheet" type="text/css">
<link href="http://xymostech.com/katex/fonts/fonts.css" rel="stylesheet" type="text/css">
<script src="http://xymostech.com/katex/katex.min.js"></script>
It would work if it could be changed to:
<link href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.6.0/katex.min.css" rel="stylesheet" type="text/css">
<link href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.6.0/fonts.css" rel="stylesheet" type="text/css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.6.0/katex.min.js"></script>
Looks like someone made the proposed changes in https://jsperf.com/katex-vs-mathjax/47. It's still not working, but it looks like an unrelated issue in the setup code.
Perhaps this link could be removed from the README until it's working - I just ran into this as well (also giving a "ReferenceError: katex is not defined" as well as the MathJax error).
<shamelessplug>
In the meantime, here's my KaTeX-MathJax speed comparison: http://www.intmath.com/cg5/katex-mathjax-comparison.php
</shamelessplug>
@mbourne would you be okay with us pointing to your speed comparison in the README?
@mbourne Great examples! (And wow, what a speedup -- I get 25x on desktop and 50x on mobile.) Helpful also to have the bad examples.
I tried the cross product example and, while it indeed looks bad in KaTeX and good in MathJax, it actually looks the same as KaTeX in PDFLaTeX. (See also #594.) Another solution would be to change the \\ into \\[0.5ex] for example, which works in LaTeX and KaTeX (didn't try MathJax).
On the other hand, Maxwell's Equation looks much better in LaTeX than KaTeX, so that's a bug (#531).
\overrightarrow is coming soon, I hope (#524). \underset seems feasible, but no concrete plans yet (#484).
Maxwell's Equations look fine with extra vertical spacing eg using \\ \\. See IntMath Samples option at http://sixthform.info/katex/examples/demo.html
I also used different (and variable) vertical spacing for the Cross Product, but then I expect to do that sort of adjustment in LaTeX when using fractions in matrices or align environments etc, so I'm not bothered by the need to do so in KaTeX.
@kevinbarabash: Feel free to include it in the README.
@edemaine: Thanks for your kind comments.
I just tried the online version http://jsperf.com/katex-vs-mathjax/ and it fails. I'm a newbie, but this looks bad for your project when your own test can't complete!
Testing in Chrome 55.0.2883 / Mac OS X 10.11.6
Now that we're pointing to http://www.intmath.com/cg5/katex-mathjax-comparison.php in the README maybe we should delete the jsperf test.
Oh, do you have access to change the jsperf test? I thought we had to make a new one. I think jsperf would be better/good in addition -- it has trustworthy measurement technology.
I can't get jsperf.com to even load. If it comes back online we can re-open this and try to figure out how to update the perf test. If we're concerned about accuracy of the new katex-mathjax comparison we might look at using https://github.com/bestiejs/benchmark.js (this is what jsperf uses), but the difference in speed right now is at least an order of magnitude so I wouldn't bother.