Search code examples
javascripthtmlcachingmathjax

MathJax stops working once the js cached in the browser


I have this formula: ({\Delta ^{ - 1}} - T{V_0})

It works perfectly fine when I open the 1st the webpage. As soon as i refresh or open it again, the formula is diplayed in it raw format.

When I remove the browser cache, it work again the next time.

Any idea?

I have tried with Firefox, Chrome.

Thanks.


Solution

  • Thanks for your help Davide, but I figured out what the problem was. In fact, one part of the page was loaded with Ajax, so mathjax was running before the page was loaded. What happened from time to time, is that when I cleared the cache, the ajax page was loaded a bit earlier that the mathjax script, so it worked. What I did is that I reloaded mathjax once the ajax page was loaded and everything works as a charm.

    MathJax.Hub.Queue(["Typeset",MathJax.Hub]);