Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable MathJax in presentation mode? #12

Open
borkdude opened this issue Feb 19, 2013 · 1 comment
Open

Enable MathJax in presentation mode? #12

borkdude opened this issue Feb 19, 2013 · 1 comment

Comments

@borkdude
Copy link

I'm not at home enough in javascript/clojurescript, so alas I have no code attached. It would be useful if MathJax kept working in presentation mode. Is this an easy adaptation to the existing code?

@borkdude
Copy link
Author

A possible fix:

Call (.Queue js/MathJax.Hub (into-array ["Typeset",MathJax.Hub])) at the end of show-slide:

(defn show-slide [{:keys [id html]}]
  (set-location-fragment id)
  (set! (. (dom/getElement "current-slide") -innerHTML) html)
  (show-presenter-slides)
  (.Queue js/MathJax.Hub (into-array ["Typeset",MathJax.Hub]))

Two problems:

  • this needs an externs file, else the names get munged
  • should include a check if MathJax is in use: (when js/MathJax ...), is that the way to check?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant