org-reveal
org-reveal copied to clipboard
Improved customization of MathJax
With respect to the MathJax support in org-reveal
, I've encountered a few pain points:
- I'd like to be able to specify a MathJax configuration to use (both globally, i.e. a default one, and locally, i.e. per-buffer basis). For example, I make heavy use of the
physics
package, so it would be nice to make this available in all my Reveal.js presentations too (which can be done through the MathJax config). - It would be nic to be able to switch between different MathJax versions.
This PR attempts to address the above while maintaining the current behaviors.
Configurations can now be specified by:
- In buffer:
#+REVEAL_MATHJAX_CONFIG
- Through customization:
org-reveal-mathjax2-config
ororg-reveal-mathjax3-config
, depending on which MathJax version we're working with.
Version of MathJax is specified by::
- In buffer:
#+REVEAL_MATHJAX_VERSION: 2.7.5
- Custom variablle:
org-reveal-mathjax-version
- If
REVEAL_MATHJAX_URL
is specified, andorg-reveal-extract-mathjax-version-from-url
is non-nil, we will attempt to extract the version from the URL. - Otherwise, defaults to 2.7.5, as is currently done.
I personally find this quite useful, so figured I'd make a PR:)
Also, love the package! Rely on it for all my presentation needs, so thank you so much for your work!
EDIT: If there's interest in this, I can of course also add a README section about this :+1: