diff options
Diffstat (limited to 'nikola/data/themes/default/assets/js/mathjax.js')
| -rw-r--r-- | nikola/data/themes/default/assets/js/mathjax.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/nikola/data/themes/default/assets/js/mathjax.js b/nikola/data/themes/default/assets/js/mathjax.js new file mode 100644 index 0000000..2f4e773 --- /dev/null +++ b/nikola/data/themes/default/assets/js/mathjax.js @@ -0,0 +1,12 @@ +// We wait for the onload function to load MathJax after the page is completely loaded. +// MathJax is loaded 1 unit of time after the page is ready. +// This hack prevent problems when you use social button from addthis. +// +window.onload = function () { + setTimeout(function () { + var script = document.createElement("script"); + script.type = "text/javascript"; + script.src = "https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS_HTML"; + document.getElementsByTagName("body")[0].appendChild(script); + },1) +}
\ No newline at end of file |
