Skip to content

Commit ad9bb99

Browse files
authored
Update chat.js
1 parent f4cd3c2 commit ad9bb99

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

docs/assets/chat.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,13 @@
2828
}
2929

3030
function mount() {
31-
const root = document.getElementById("doccoach-root");
32-
if (!root) return;
31+
let root = document.getElementById("doccoach-root");
32+
if (!root) {
33+
root = document.createElement("div");
34+
root.id = "doccoach-root";
35+
document.body.appendChild(root);
36+
}
37+
3338

3439
let open = false;
3540
let includePage = true;

0 commit comments

Comments
 (0)