SID-02461: MathJax rendering
| Status: |
Answered |
TWiki version: |
6.1.0 |
Perl version: |
5.30.0 |
| Category: |
LatexModePlugin |
Server OS: |
Ubuntu 20.04 |
Last update: |
5 years ago |
I would like to use
MathJax to render
LaTeX within TWiki. I cannot find directions; support for
LaTeX seems to predate
MathJax. I suspect it is simple, but I don't speak Perl and am hoping someone else has already figured this out.
--
Peter Saeta - 2020-12-05
Discussion and Answer
Since
MathJax is all browser-based
JavaScript you can simply include the library, and post the math text using TeX, MathML, or AsciiMath syntax.
Step 1: Include the mathjax JavaScript: (view raw page source)
Including this JavaScript could be done by a plugin, or a site-wide preferences setting, so that you could simply write %USEMATHJAX% in a topic to use MathJax. Or, you could add it to a TWiki template so that it is available in all topics by default. You could hire one of the
TWikiConsultants to help you out.
Step 2: Enter math text:
- TeX: \(\frac a b\)
- MathML:
- AsciiMath: `a^2 + b^2 = c^2`
--
Peter Thoeny - 2020-12-05
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.