Skip to content

Commit b210cec

Browse files
committed
chore: update comment
1 parent 99233e5 commit b210cec

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

packages/react/src/schema/@util/ReactRenderUtil.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,11 @@ export function renderToDOMSpec(
2020
div
2121
);
2222
} else {
23-
// If no editor is provided, or if _tiptapEditor or _tiptapEditor.contentComponent is undefined, use a temporary root.
24-
// This is currently only used for Styles. In this case, react context etc. won't be available inside `fc`
23+
// If no editor is provided, use a temporary root. This is currently only used for Styles (see ReactStyleSpec).
24+
// In this case, react context etc. won't be available inside `fc`
25+
26+
// We also use this if _tiptapEditor or _tiptapEditor.contentComponent is undefined, use a temporary root.
27+
// This is actually a fallback / temporary fix, as normally this shouldn't happen (see #755). TODO: find cause
2528
root = createRoot(div);
2629
flushSync(() => {
2730
root!.render(fc((el) => (contentDOM = el || undefined)));

0 commit comments

Comments
 (0)