mirror of
https://github.com/discourse/discourse-math.git
synced 2025-06-29 10:42:11 +00:00
FIX: allows polls to work with discourse-math (#110)
This commit is contained in:
parent
b1cc1481c9
commit
e7ef2ec223
@ -1,4 +1,4 @@
|
||||
import { later } from "@ember/runloop";
|
||||
import { later, next } from "@ember/runloop";
|
||||
import { getURLWithCDN } from "discourse/lib/get-url";
|
||||
import loadScript from "discourse/lib/load-script";
|
||||
import { withPluginApi } from "discourse/lib/plugin-api";
|
||||
@ -112,7 +112,9 @@ function mathjax(elem, opts) {
|
||||
function initializeMath(api, discourseMathOptions) {
|
||||
api.decorateCookedElement(
|
||||
(element) => {
|
||||
mathjax(element, discourseMathOptions);
|
||||
next(() => {
|
||||
mathjax(element, discourseMathOptions);
|
||||
});
|
||||
},
|
||||
{ id: "mathjax" }
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user