Skip to main content

MathJax

The @liqvid/mathjax package helps with using MathJax in Liqvid videos.

Examples​

Revealing equations​

  • Refresh

Fading equations​

  • Refresh

Exports​

Handle​

Type of refs attached to <MJX> components.

  • domElement: HTMLSpanElement
    Underlying <span> element.

  • ready: Promise<void>
    A Promise that will resolve once the element has finished typesetting.

<MJX>​

Component for including math; contents will be rendered using MathJax.

Props​

This component accepts the following props. Any additional attributes will be forwarded to the underlying <span> element.

  • display?: boolean = false
    Whether to render in displaystyle.

  • obstruct?: string = "canplay canplaythrough"
    Player events to obstruct.

  • reparse?: boolean = false
    Whether to reparse the tree.

<MJXText>​

Element which will render any MathJax contained inside.

Props​

This component accepts the following props. Any additional attributes will be forwarded to the underlying element.

  • tagName?: keyof (HTMLElementTagNameMap & JSX.IntrinsicElements) = "p"
    HTML tag to insert.

<RenderGroup>​

Container for if you need to use .ready or .reparse on multiple <MJX> elements at once.

Props​

This component accepts the following props:

  • reparse?: boolean = false
    Whether to reparse the tree once all <MJX> descendants are ready.

Properties​

Refs attached to this component have the following properties:

  • ready: Promise<void>
    A Promise that resolves once all <MJX> descendants are ready.