From 0219ab2d4e91dafd798ff3d438a793b85df4645b Mon Sep 17 00:00:00 2001 From: Gerard Rovira Date: Sun, 5 May 2024 15:02:24 -0400 Subject: [PATCH] Dev warning for failed DOM selection --- packages/lexical/src/LexicalSelection.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/lexical/src/LexicalSelection.ts b/packages/lexical/src/LexicalSelection.ts index 8bd4f1467d9..1b493f8757b 100644 --- a/packages/lexical/src/LexicalSelection.ts +++ b/packages/lexical/src/LexicalSelection.ts @@ -2657,6 +2657,9 @@ export function updateDOMSelection( // If we encounter an error, continue. This can sometimes // occur with FF and there's no good reason as to why it // should happen. + if (__DEV__) { + console.warn(error); + } } if ( !tags.has('skip-scroll-into-view') &&