为什么无法在本地托管我自己的 MathJax 副本?

问题描述 投票:0回答:1
javascript mathjax
1个回答
0
投票

我在这里看到的是版本不匹配,因此,初始化库的解决方案。您尝试使用最新版本初始化库,这是旧方法。 我重复了你的 HTML,确实没有任何错误。所以我打开了关于“开始使用”部分的官方文档,它说在那里,而不是你的 <script type="text/x-mathjax-config"> MathJax.Hub.Config({ tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}, }); </script>

在加载库之前必须预定义常量

<script> MathJax = { tex: { inlineMath: [['$', '$'], ['\\(', '\\)']] } }; </script>

所以你的 HTML 可能看起来像这样

<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width"> <script type="text/javascript"> MathJax = { tex: { inlineMath: [['$', '$'], ['\\(', '\\)']] } }; </script> <script type="text/javascript" src="http://127.0.0.1/mathjax/es5/tex-chtml.js?config=TeX-MML-AM_CHTML"> </script> </head> <body> First of all, we can "relax" the $\forall$-Introduction rule : $A \to B \vdash A \to \forall x B$, provided that $x$ is not *free* in $A$. </body> </html>

	
© www.soinside.com 2019 - 2024. All rights reserved.