dabakovich / react-native-controlled-mentions

Fully controlled React Native mentions component
MIT License
223 stars 82 forks source link

Undefined keyword in renderSuggestions #128

Open divyamori opened 10 months ago

divyamori commented 10 months ago

getting undefined keyword when clear every character, Each time I type another letter i do a small jump in the screen.

Screenshot 2023-12-27 at 10 29 05 AM
divyamori commented 9 months ago

Hello

Thank you for replying, if possible to can you send me sample code or any link which you have used that code.

Thank you

On Thu, Jan 25, 2024, 3:21 AM mikenoriega @.***> wrote:

Same happened to me and I noticed I was using ref in my previous input. I had to change that to use value and onchange props like in the example, that way I dont get undefined value in keyboard

— Reply to this email directly, view it on GitHub https://github.com/dabakovich/react-native-controlled-mentions/issues/128#issuecomment-1908974176, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC3PC3IVI7MXW2FWUHGQE7TYQF66JAVCNFSM6AAAAABBD5ST5OVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMBYHE3TIMJXGY . You are receiving this because you authored the thread.Message ID: @.*** com>

ramezrafla commented 3 weeks ago

@dabakovich -- thanks so much for the best mentions library for RN We are facing the bug above when using v3 (i.e. with hooks) -- maybe it's present in the main branch

When we backspace, we get keyword undefined, then it corrects itself. Not a biggie, we can handle in the calling component, but it would be great if it's resolved.

Or share guidance, the code is too complex to figure out at first glance. There is a note about RN bug (in getTriggerPartSuggestionKeywords), maybe that's what it is?