We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c399a6 commit 1182592Copy full SHA for 1182592
packages/share-theme/src/scripts/modules/math.ts
@@ -9,6 +9,8 @@ export default async function setupMath() {
9
const renderMathInElement = (await import("katex/contrib/auto-render")).default;
10
await import("katex/contrib/mhchem");
11
12
- renderMathInElement(document.getElementById("content"));
+ const contentEl = document.getElementById("content");
13
+ if (!contentEl) return;
14
+ renderMathInElement(contentEl);
15
document.body.classList.add("math-loaded");
16
}
0 commit comments