fast-reflexes/better-react-mathjax

MathJax is getting applied outside of MathjaxContext

vikram-typeset opened this issue · 2 comments

Hi, I am trying to use this library for formatting a math expression. I have a usecase where out of the 3 expression in a page, I want to format only 1. But all 3 are getting formatted. I have create 2 sandbox and added a comment. Please check. Let me know if I am doing something wrong. Thanks.

Hi!

Mathjax typesets automatically once when it is first downloaded. To disable this, add the following config to the MathJaxContext:

  const config = {
    startup: {
      typeset: false
    }
  }

Then only the math inside the MathJax component will be typset :)

PS! This config is for MathJax 3, there is an equivalent for MathJax 2 as well DS

Hi, Thanks for the help. It's worked.