如何防止MathJax在等待渲染完成时显示原始TeX? [英] How do I prevent MathJax from showing raw TeX while waiting for rendering to complete?

查看:355
本文介绍了如何防止MathJax在等待渲染完成时显示原始TeX?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的网页上有一些MathJax,并希望什么都不会出现,直到MathJax完成对方程的处理:没有原始的 LaTeX 和加载进度指示器.

是否可以通过MathJax配置设置来完成此任务?

解决方案

嘿,如果您仍然需要答案,请尝试以下操作.

如果调用MathJax.Hub.Config(),则将参数preview: "none"传递给配置中的tex2jax对象.像这样:

MathJax.Hub.Config({

   tex2jax:
   {
      preview: "none"
   }

});

这不会显示MathJax将拾取的任何原始tex命令.它将使您仍然可以在标记中显示其他元素,从而使页面在浏览器呈现时不会显得空白.

希望这会有所帮助.

I have some MathJax on my webpage and would like nothing to appear until the MathJax has finished processing my equations: no raw LaTeX and no loading progress indicator.

Is there a way to accomplish this with MathJax configuration settings?

解决方案

Hey if you still need an answer, try the following.

If you call MathJax.Hub.Config(), pass the parameter preview: "none" to the tex2jax object in the config. Like so:

MathJax.Hub.Config({

   tex2jax:
   {
      preview: "none"
   }

});

This will not show any raw tex commands that MathJax will pick up. It will allow to you still display other elements in your markup so your page doesn't look blank as the browser renders it.

Hope this helps.

这篇关于如何防止MathJax在等待渲染完成时显示原始TeX?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆