Closed JokerNN closed 7 years ago
Hello, first of all thanks for your library
I faced an issue while using this. After first unmount of Textarea main component list navigation with keys becomes impossible. It happens because Textarea.jsx calls removeAll here https://github.com/webscopeio/react-textarea-autocomplete/blob/master/src/Textarea.jsx#L92
removeAll
Which removes keydown event listener forever (until page refresh). Next mounts of Textarea components won't work properly.
keydown
I fixed it roughly here https://github.com/webscopeio/react-textarea-autocomplete/compare/master...JokerNN:master
This change effectively means that keydown event listener will persist forever. (downside of global singletone listener)
I will get rid of it in PR
Hi,
thanks for feedback and issue report. I'll also look on it, I wasn't aware of this behavior.
Anyway, PR is welcomed! ❤️
Closed by #17
Upgrade to v1.1.4. Thanks. 👍
Hello, first of all thanks for your library
I faced an issue while using this. After first unmount of Textarea main component list navigation with keys becomes impossible. It happens because Textarea.jsx calls
removeAll
here https://github.com/webscopeio/react-textarea-autocomplete/blob/master/src/Textarea.jsx#L92Which removes
keydown
event listener forever (until page refresh). Next mounts of Textarea components won't work properly.I fixed it roughly here https://github.com/webscopeio/react-textarea-autocomplete/compare/master...JokerNN:master
This change effectively means that
keydown
event listener will persist forever. (downside of global singletone listener)I will get rid of it in PR