sphinx-exercise
sphinx-exercise copied to clipboard
mathjax loading on per page basis causes issue for nodes containing math in reference only
Describe the problem
It looks like mathjax doesn't get loaded by sphinx on page that contains nodes that reference math but don't explicitly include math on that page
For example:
.. solution:: exercise-1
:label: solution-1
This is a solution to exercise 1
references
.. exercise:: :math:`n!` factorial
:label: exercise-1
Exercise 1 about :math:`n!` factorial
But will result in:
but if you add a math role anywhere on that page it will be correctly rendered.
Link to your repository or website
No response
Steps to reproduce
- Have a page with solution nodes only with references to
exercise
nodes that contain math in the titles
The version of Python you're using
No response
Your operating system
No response
Versions of your packages
No response
Additional context
I suspect this relates to loading mathjax on a per page basis
https://github.com/sphinx-doc/sphinx/issues/9686