fix: check whether the component is defined already (#337)
Co-authored-by: Matas <automatasz@users.noreply.github.com> Co-authored-by: Katsuyuki Karasawa <4ranci0ne@gmail.com>
This commit is contained in:
parent
477d184fc5
commit
ac75858fd2
1 changed files with 3 additions and 2 deletions
|
|
@ -256,6 +256,7 @@ class TableOfContents extends HTMLElement {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
customElements.define("table-of-contents", TableOfContents);
|
if (!customElements.get("table-of-contents")) {
|
||||||
|
customElements.define("table-of-contents", TableOfContents);
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
Loading…
Reference in a new issue