diff --git a/packages/editor/core/src/hooks/use-editor.tsx b/packages/editor/core/src/hooks/use-editor.tsx index f5500e725..ae7d90342 100644 --- a/packages/editor/core/src/hooks/use-editor.tsx +++ b/packages/editor/core/src/hooks/use-editor.tsx @@ -112,12 +112,9 @@ export const useEditor = ({ editor.commands.setContent(value); const currentSavedSelection = savedSelectionRef.current; if (currentSavedSelection) { - editor.view.focus(); const docLength = editor.state.doc.content.size; const relativePosition = Math.min(currentSavedSelection.from, docLength - 1); editor.commands.setTextSelection(relativePosition); - } else { - editor.commands.focus("end"); } } catch (error) { console.error("Error syncing editor content with external value:", error);