Skip to content

Commit 776de2b

Browse files
committed
This config seems to work
1 parent a78bd96 commit 776de2b

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

webapp/templates/base.html.twig

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
<script src="{{ asset("js/jquery.min.js") }}"></script>
1414
<script src="{{ asset("js/jquery.debounce.min.js") }}"></script>
1515
<script src="{{ asset("js/bootstrap.bundle.min.js") }}"></script>
16+
<!--
1617
<script>
1718
window.MathJax = {
1819
tex: { inlineMath: [['$', '$'], ['\\(', '\\)']] },
@@ -28,6 +29,25 @@
2829
};
2930
</script>
3031
<script src="{{ app.request.basePath }}/mathjax/tex-chtml.js"></script>
32+
-->
33+
<script>
34+
window.MathJax = {
35+
tex: {
36+
inlineMath: [['$', '$'], ['\\(', '\\)']]
37+
},
38+
chtml: {
39+
fontURL: "{{ app.request.basePath }}/mathjax/fonts/TeX", // local TeX font path
40+
scale: 1.0
41+
},
42+
loader: {
43+
paths: {
44+
mathjax: "{{ app.request.basePath }}/mathjax"
45+
},
46+
load: ['input/tex', 'output/chtml']
47+
}
48+
};
49+
</script>
50+
<script src="{{ app.request.basePath }}/mathjax/tex-chtml.js"></script>
3151

3252
<script src="{{ asset("js/domjudge.js") }}"></script>
3353
{% for file in customAssetFiles('js') %}

0 commit comments

Comments
 (0)