Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions docs/javascripts/mathjax.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
// MathJax config for Material for MkDocs + pymdownx.arithmatex (generic mode).
// MathJax config covering both rendering paths on this site:
// - Markdown pages via pymdownx.arithmatex (generic): math arrives as
// \(...\) / \[...\] inside `arithmatex` spans.
// - Jupyter notebooks via mkdocs-jupyter: math arrives as raw $...$ / $$...$$.
// So we accept both delimiter styles and let MathJax scan the whole page (it
// skips <pre>/<code>/<script> by default, so $ in code is untouched).
window.MathJax = {
tex: {
inlineMath: [["\\(", "\\)"]],
displayMath: [["\\[", "\\]"]],
inlineMath: [["\\(", "\\)"], ["$", "$"]],
displayMath: [["\\[", "\\]"], ["$$", "$$"]],
processEscapes: true,
processEnvironments: true,
},
options: {
ignoreHtmlClass: ".*|",
processHtmlClass: "arithmatex",
},
};

// Re-typeset on Material's instant-navigation page loads.
Expand Down
Loading