diff --git a/src/pages/home/report/ReportActionCompose/SuggestionMention.js b/src/pages/home/report/ReportActionCompose/SuggestionMention.js index 6c08b68cdc78..fea1f2e845a5 100644 --- a/src/pages/home/report/ReportActionCompose/SuggestionMention.js +++ b/src/pages/home/report/ReportActionCompose/SuggestionMention.js @@ -234,7 +234,10 @@ function SuggestionMention({ useEffect(() => { calculateMentionSuggestion(selection.end); - }, [selection, calculateMentionSuggestion]); + + // We want this hook to run only on selection change. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [selection]); const updateShouldShowSuggestionMenuToFalse = useCallback(() => { setSuggestionValues((prevState) => {