Skip to content

Commit 0cdd3bb

Browse files
committed
improve example for how to control typeset at startup
1 parent ff983b6 commit 0cdd3bb

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

devtools/test_dashboard/index-mathjax3.html

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,26 @@
1616

1717
<section id="mocks-list"></section>
1818

19-
<p>MathJax $V^3$ with $svg$ output on the page as well as plotly graphs</p>
19+
<p id="pWithMathJax">MathJax $V^3$ with $svg$ output on the page as well as plotly graphs</p>
20+
<h4>no MathJax: Apple: $2, Orange: $3</h4>
21+
2022
<div id="plots">
2123
<div id="graph"></div>
2224
</div>
2325
<div id="snapshot"></div>
2426

27+
<script>
28+
window.MathJax = {
29+
startup: {
30+
elements: [
31+
document.getElementById('pWithMathJax')
32+
],
33+
// typeset: false,
34+
// in case the elements array is empty one could disable startup typeset
35+
// https://docs.mathjax.org/en/latest/options/startup/startup.html#the-configuration-block
36+
}
37+
};
38+
</script>
2539
<script src="../../node_modules/mathjax-v3/es5/tex-svg.js"></script>
2640
<script charset="utf-8" id="source" src="../../build/plotly.js" type="module"></script>
2741
<script charset="utf-8" src="../../build/test_dashboard-bundle.js"></script>

0 commit comments

Comments
 (0)