Skip to content

Commit

Permalink
Revert "Handle suggestions only on selection change"
Browse files Browse the repository at this point in the history
This reverts commit a4f4a77.
  • Loading branch information
cubuspl42 committed Oct 4, 2023
1 parent 0b3b3ec commit 89ac222
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -234,10 +234,7 @@ function SuggestionMention({

useEffect(() => {
calculateMentionSuggestion(selection.end);

// We want this hook to run only on selection change.
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [selection]);
}, [selection, calculateMentionSuggestion]);

const updateShouldShowSuggestionMenuToFalse = useCallback(() => {
setSuggestionValues((prevState) => {
Expand Down

0 comments on commit 89ac222

Please sign in to comment.