NodeJS

react-katex

This library displays math expressions with KaTeX and React

Example:

var InlineMath = ReactKaTeX.InlineMath;

ReactDOM.render(<InlineMath math="\\int_0^\\infty x^2 dx"/>,
                document.getElementById('math'));


ReactDOM.render(<InlineMath>\int_0^\infty x^2 dx</InlineMath>,
                document.getElementById('math'));

And this will display expression like following.


Important note: don’t forget to import Katex CSS file.

import 'katex/dist/katex.min.css';

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *