webscopeio / react-textarea-autocomplete

📝 React component implements configurable GitHub's like textarea autocomplete.
MIT License
451 stars 80 forks source link

Bug. Problems with trigger if it does not consist of one character. Like in #145 issue. #167

Closed OlegVach closed 5 years ago

OlegVach commented 5 years ago

Problem with triggers. I am using 3 different triggers. "@", ":", "{{". Trigger "{{" doesn't work correctly. It shows dropdown list only after another triggers. If you try print this trigger it doesn't works.

jukben commented 5 years ago

Could you please provide steps to reproduce and expected result?

You can use this codesandbox, just tweak it for your use-case: https://codesandbox.io/s/vjx16

OlegVach commented 5 years ago

Try it. https://codesandbox.io/embed/ancient-sun-ysz9k Try set at first this symbols "{{". It will be not showing dropdown. When you set this ";" at first, and after this "{{" it will be working.

P.S Set minChar={0}.