Project Name | Stars | Downloads | Repos Using This | Packages Using This | Most Recent Commit | Total Releases | Latest Release | Open Issues | License | Language |
---|---|---|---|---|---|---|---|---|---|---|
Katex | 17,239 | 1,691 | 1,168 | 3 days ago | 75 | October 02, 2023 | 415 | mit | JavaScript | |
Fast math typesetting for the web. | ||||||||||
Type On Strap | 765 | 18 | 1 | 9 hours ago | 56 | December 04, 2023 | 3 | mit | Liquid | |
🎨 Simplistic, responsive jekyll based open source theme | ||||||||||
Marp Core | 663 | 19 | 8 | a month ago | 88 | October 15, 2023 | 9 | mit | TypeScript | |
The core of Marp converter | ||||||||||
Drawio Diagrams | 633 | 3 days ago | apache-2.0 | |||||||
Diagrams for draw.io | ||||||||||
Type Theme | 629 | 10 | 4 years ago | 3 | July 02, 2019 | 1 | mit | HTML | ||
A free and open-source Jekyll theme with responsive design. Great for blogs and easy to customize. | ||||||||||
Unicode Math | 222 | 4 months ago | 164 | lppl-1.3c | TeX | |||||
XeLaTeX/LuaLaTeX package for using unicode/OpenType maths fonts | ||||||||||
Pseudocode.js | 177 | 4 | 4 months ago | 6 | June 09, 2023 | 1 | mit | JavaScript | ||
Beautiful pseudocode for the Web | ||||||||||
Story | 155 | 2 years ago | mit | JavaScript | ||||||
Beautiful responsive Hugo blog theme focused on simplicity and elegance, with many extra features including presentations, math typesetting, music notation, and search. | ||||||||||
Pretex | 79 | 9 years ago | 10 | November 23, 2014 | TeX | |||||
LaTeX preprocessor to simplify math typesetting | ||||||||||
Yawysiwygee | 68 | 2 years ago | 2 | mit | C++ | |||||
Yet another what-you-see-is-what-you-get equation editor |
KaTeX is a fast, easy-to-use JavaScript library for TeX math rendering on the web.
KaTeX is compatible with all major browsers, including Chrome, Safari, Firefox, Opera, Edge, and IE 11.
KaTeX supports much (but not all) of LaTeX and many LaTeX packages. See the list of supported functions.
Try out KaTeX on the demo page!
<!DOCTYPE html>
<!-- KaTeX requires the use of the HTML5 doctype. Without it, KaTeX may not render properly -->
<html>
<head>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.css" integrity="sha384-n8MVd4RsNIU0tAv4ct0nTaAbDJwPJzDEaqSD1odI+WdtXRGWt2kTvGFasHpSy3SV" crossorigin="anonymous">
<!-- The loading of KaTeX is deferred to speed up page rendering -->
<script defer src="https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.js" integrity="sha384-XjKyOOlGwcjNTAIQHIpgOno0Hl1YQqzUOEleOLALmuqehneUG+vnGctmUb0ZY0l8" crossorigin="anonymous"></script>
<!-- To automatically render math in text elements, include the auto-render extension: -->
<script defer src="https://cdn.jsdelivr.net/npm/[email protected]/dist/contrib/auto-render.min.js" integrity="sha384-+VBxd3r6XgURycqtZ117nYw44OOcIax56Z4dCRWbxyPt0Koah1uHoK0o4+/RRE05" crossorigin="anonymous"
onload="renderMathInElement(document.body);"></script>
</head>
...
</html>
You can also download KaTeX and host it yourself.
For details on how to configure auto-render extension, refer to the documentation.
Call katex.render
to render a TeX expression directly into a DOM element.
For example:
katex.render("c = \\pm\\sqrt{a^2 + b^2}", element, {
throwOnError: false
});
Call katex.renderToString
to generate an HTML string of the rendered math,
e.g., for server-side rendering. For example:
var html = katex.renderToString("c = \\pm\\sqrt{a^2 + b^2}", {
throwOnError: false
});
// '<span class="katex">...</span>'
Make sure to include the CSS and font files in both cases. If you are doing all rendering on the server, there is no need to include the JavaScript on the client.
The examples above use the throwOnError: false
option, which renders invalid
inputs as the TeX source code in red (by default), with the error message as
hover text. For other available options, see the
API documentation,
options documentation, and
handling errors documentation.
Learn more about using KaTeX on the website!
This project exists thanks to all the people who contribute code. If you'd like to help, see our guide to contributing code.
Become a financial contributor and help us sustain our community.
Support this project with your organization. Your logo will show up here with a link to your website.
KaTeX is licensed under the MIT License.