Search mechanism: Prioritise StartsWith and then Contains

Hi,

I am trying to write a custom search with SfAutoComplete that behaves in the following way:

1. It should first look for items that Start with the search phrase (NOT case-sensitive)
2. It will then include the items that do not start with the search phrase but contain the search phrase. 


How can I get that order right?

Thanks! 

1 Reply

SS Suganya Sethuraman Syncfusion Team February 3, 2021 12:40 PM UTC

Hi Amir,

Greetings from Syncfusion.

We have analyzed your requirement.
We cannot filter it like that. In our custom filter, we can only decide whether or not the item should be listed on the basis of the criteria.

Please let us know if you have any other queries.

Regards,
Suganya Sethuraman.
 


Loader.
Up arrow icon