prosemirror-math

This package provides ProseMirror schema and plugins for comfortably writing mathematics in a WYSIWYG style. Written in TypeScript, with math rendering handled by KaTeX.

Basic Usage:
  • Inline math nodes are delimited with $. After typing the closing dollar sign in an expression like $\int_a^b f(x) dx$, a math node will appear.
  • To start a block math node, press Enter to create a blank line, then type $$ followed by Space. You can type multi-line math expressions, and the result will render in display style.
  • Math nodes behave like regular text when using arrow keys or Backspace. From within a math node, press Ctrl-Backspace to delete the entire node.
  • You can select, copy, and paste math nodes just like regular text!
  • See the KaTeX documentation for a list of supported commands. In the future, you will also be able to use alternative renderers like MathJax.
  • You can define your own commands with \providecommand{\cmd}{...}!

The text below this line is all editable, including the math! Go ahead, try it!