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 3e13fa9 commit c93b468Copy full SHA for c93b468
1 file changed
packages/core/src/editor/BlockNoteEditor.ts
@@ -681,7 +681,7 @@ export class BlockNoteEditor<
681
*/
682
public mount = (element: HTMLElement) => {
683
const root = element.getRootNode();
684
- if (root instanceof ShadowRoot) {
+ if (typeof ShadowRoot !== "undefined" && root instanceof ShadowRoot) {
685
root.appendChild(this.portalElement);
686
} else {
687
document.body.appendChild(this.portalElement);
0 commit comments