How to detect when mathjax is fully loaded?

前端 未结 2 1274
礼貌的吻别
礼貌的吻别 2020-12-31 03:35

Is there anyway to identify when the mathjax is fully loaded to process mathematics. I need to hide my mathematics equations before mathjax is fully loaded and show \'loadin

2条回答
  •  心在旅途
    2020-12-31 04:27

    For those who might be looking for the answer, this is the response i got from Mathjax developer

    The way to synchronize with MathJax's startup actions it to register a StartupHook that will fire when the startup is complete. For example, you can use

    MathJax.Hub.Register.StartupHook("End",function () { ... your startup code here ... });

    at the end of the tag that configures MathJax, or in a separate tag just after loading MathJax if you are using the default MathJax configuration file in MathJax/config/MathJax.js. That should let you hook into MathJax's initialization sequence so you can do your own setup at the right time.

    Thanks David

提交回复
热议问题