Skip to content
Advertisement

Tag: mathjax

Rendering MathJax after loading content with jQuery

I load some content containing math with jQuery into my html file. Now I want Mathjax to typeset this new content, but it doesn’t work. This is what my JavaScript code looks like But it only loads the content without applying MathJax. Any suggestions why it is not working? Edit I added a second button with a second click function,

Preview Text with MathJax Using async

Below is an example of a text preview using jQuery. I would have thought inserting the following snippet in the third line would preview MathJax. I am confused why adding this portion does not convert LaTeX. How can I activate MathJax to make it convert the message below in only the preview below? I have seen other examples of this

Why doesn’t \ display a newline in mathjax?

I am under the impression that you should use \ for newlines with mathjax, however I can’t get it to work. What am I doing wrong here? I expect to see 3 lines, but I get this: Other stackoverflow posts claim that \ should work, eg: https://math.meta.stackexchange.com/questions/11720/new-line-within-mathjax Answer You should use HTML to break lines as MathJax only handles math

Advertisement