Closed codingfrenzyyyy closed 2 years ago
How are you setting up those 4000-5000 (presumably) actions? You should be able to search through 4-5k actions without any performance hit
Our implementation is similar to the example you have given, where we use useRegisterActions to dynamically pull the search set once, and calls useMatches() hook to return and render the searched results.
Yes as mentioned, there are no performance hit when we are typing 5-6 characters in KBarSearch component. However weirdly upon more characters entered, it hangs or lags. It is a prominent issue when we hold down a keyboard key (eg. we hold down 'c' character key in KBarSearch input, when the search set is 4000-5000 actions).
This issue is not observed with smaller search sets.
I wonder could it be due to the way getDeepResults or collectChildren are written?
Each action has 4-5 keywords. Does it contribute to the performance of typing in search input?
hi, the issue has been fixed by removing some of the longer keywords in around 40-50 search set.
Thanks for the support, but I would also like to take the chance to feedback that the performance is impacted when the keywords provided is too long.
Would be nice if the keyword matching algorithm can be optimized further.
Thanks!
Hi, i am searching through a pool of 4000-5000 search set. After typing 6-7 characters, the search gets stucky and sometimes hangs the web app. It only happens when the search set are big.
Kindly assist, thanks.