Add Mathjax to rustdoc output

when generating local documentation, this requires `RUSTDOCFLAGS=--html-in-header docs/mathjax.html` for math to be rendered.
master
Andrew Cassidy 1 year ago
parent bddc3e1977
commit e943345693

@ -9,3 +9,9 @@ edition = "2021"
generic_parameterize = "0.1.0"
itertools = "0.10.5"
num-traits = "0.2.15"
[package.metadata.docs.rs]
rustdoc-args = [
"--html-in-header",
"doc/mathjax.html",
]

@ -0,0 +1,11 @@
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
asciimath2jax: {
delimiters: [['$','$']]
}
});
</script>
<script type="text/javascript" async
src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/MathJax.js?config=TeX-MML-AM_CHTML">
</script>
Loading…
Cancel
Save