localkatex

Render math using KaTeX while building the site

To install, run nikola plugin -i localkatex

A plugin that renders math using a local KaTeX install.

Requirements

  • node.js installed, in $PATH, accessible as the node command
  • KaTeX accessible by Node (run npm install in this plugin’s folder)
  • USE_KATEX = True in config

You may also edit math_helper.tmpl to remove the KaTeX JavaScript includes (which are now unused).

Examples:

Inline:

Euler’s formula: 

Display:



Alternate name:


The following options are supported: displayMode, display (alias), throwOnError, errorColor, colorIsTextColor — see KaTeX docs for details.

Suggested Configuration:

# Enable KaTeX styles
USE_KATEX = True

# Make sure you run `npm install` in this plugin’s directory.

Issues? Questions?

You can report issues with this plugin and request help via GitHub Issues.