I am using Mathjax to render fractions in a div. The first time it renders, it displays a formula (Latex) in the div briefly, which then changes to the fraction that I want the way I want to see it. This happens only the first time a fraction is rendered. I have tried running Mathjax Typeset when the page first loads, but it has not helped. Is there any way to suppress this?
As Peter mentioned in his comment above, MathJax cannot run until after the page is loaded, and when it does it must load the files that it needs for the configuration that you have selected. That means the unprocessed page will be visible to the reader until the MathJax files are loaded and it runs. So what you are seeing is normal. The reason that it only happens the first time is that when you reload the page, the MathJax files are already in the browser cache, so don't need to be retrieved over the network again, and MathJax can process the page faster (though the original LaTeX code may still be visible briefly).
This is inherent in the way that MathJax operates, and there is no easy way to prevent it. As Peter suggests, it is possible to use CSS to hide the page until after MathJax has completed its processing, but that is only useful for pages without very much math on them (otherwise the page will appear blank for a long time). See these examples, especially the one on display:none
for one approach. See also this example for how to hide the page until the math is loaded. You will need to view the source code to see how it works.
It is also possible to put your LaTeX into the <script>
tags that MathJax uses internally to store the math in the page (see the documentation for details), so that they won't be visible in the page initially, but you may still see the page without the math when it first loads, and then the typeset math will appear after MathJax runs.
Neither is an ideal solution.