rr-markdownmathjaxquarto

How can I get mathcal symbols to render with chromium browsers in R Markdown and Quarto on Mac OS?


I would like to use $\mathcal{S}$ in an rmarkdown document to render a cursive S in a formula but it renders as a square. I can see this is a known problem and can be fixed with tweaks to mathjax https://math.meta.stackexchange.com/questions/35669/chrome-doesnt-display-some-symbols.

Can anyone please tell me how to instantiate this fix in R Markdown and Quarto documents?


Solution

  • For quarto you could try the following (untested):

    According to the solution you provided, this might work:

    format:
      html:
        html-math-method:  
          method: mathjax
          url: "https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js"
    

    For rmarkdown this could help.