How would one search the virtualized list? #481
-
Let's say a user expects to hit CTRL+F and find an item that has not yet been rendered, how should this be handled with a virtualized list? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
I don't think you can do that with virtualized list. However there can be different way to search the list such as adding a search text field. |
Beta Was this translation helpful? Give feedback.
-
Hi @nemonemi! You should call a callback to find the item index in your data array. Then you can use scrollToIndex() from your |
Beta Was this translation helpful? Give feedback.
Hi @nemonemi! You should call a callback to find the item index in your data array. Then you can use scrollToIndex() from your
virtualizer
index asvirtualizer.scrollToIndex(fooundIndex)
. This is from top of my head & not tested but should work.