Skip to content
New issue

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

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

Already on GitHub? # 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?

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

No branches or pull requests

1 participant