diff --git a/static/js/MathJaxPolyfill.js b/static/js/MathJaxPolyfill.js index 6c09d8ce..66f83b30 100644 --- a/static/js/MathJaxPolyfill.js +++ b/static/js/MathJaxPolyfill.js @@ -1,8 +1,10 @@ function MathJaxPolyfillInit(){ - var typesetPromise = function() { - return new Promise(function (resolve, reject) { - MathJax.Hub.Queue(["Typeset",MathJax.Hub],[resolve]); - }) + if (!MathJax.typesetPromise) { + var typesetPromise = function() { + return new Promise(function (resolve, reject) { + MathJax.Hub.Queue(["Typeset",MathJax.Hub],[resolve]); + }) + } + MathJax.typesetPromise=typesetPromise } - MathJax.typesetPromise=typesetPromise } \ No newline at end of file