react-native-dropdown-autocomplete icon indicating copy to clipboard operation
react-native-dropdown-autocomplete copied to clipboard

how to get the suggestions by the first letter?

Open saidhappy010 opened this issue 5 years ago • 2 comments

how to get the suggestions by the first letter. for example, when I enter the letter A I would like to have suggestions that start with A. (Australia, Austria, Argentina, Armenia ......) ----> A or the S (Serbia, Slovakia, Slovenia, Switzerland .....) ------> S but the component displays me the suggestions that contain the letter A. (German, Australia, Austria, Italy, France, Japan, Netherlands ......). how could we do that. Thanks

saidhappy010 avatar Oct 09 '19 09:10 saidhappy010

Just a suggestion here, instead of using the data property which I'm guessing your using you could use the fetchData() property and implement your own search logic or use https://github.com/bvaughn/js-search.

PaitoAnderson avatar Oct 16 '19 13:10 PaitoAnderson

Please. could you give me an example about fetchData. Thank you

saidhappy010 avatar Nov 03 '19 16:11 saidhappy010