Howto navigate to "anchors" in lists using React Native? - react-native

I have an app where the user answers a lot of questions. E.g he clicks "I have a car", then I give him some new questions like "which color" and "which brand". The list is dynamic so I never know exactly how far it is from the top to the next question.
Is it possible to do something like Flatlist.scrollToLocation('#second_question')?
Well, I know scrollToLocation does not support scroll to id, but does React Native have any other lists that I can use to achieve this?
To me it looks like scrollToLocation requires that one need the exact length. Is there a list in React Native that support "scroll to anchor / id"?

Related

How i can use custom listview in react-native-google-places-autocomplete?

I have two autocompleteinputs but i want them to use same listview to look nicer. The app i am developing looks like lyft in lyft they use two text inputs in destination selection screen. How i can create autocompleteinput with custom list view?
I have readed the react-native-google-places-autocomplete documents. But didn't manage to find good solution.

Can you create a cascading dropdown in React Native?

I'm trying to make a cascading dropdown in my project where the user will first select a car brand with one dropdown, then car model from that brand, then the version and then the model year. I've been searching for it for a long time but I keep finding stuff about React JS and not react native. The documentation of react-native-dropdown-picker doesn't tell anything about something like that as well.
If anyone can help me out here, that would be great. Thanks.

React native picker long list handler

I have a long list of company names need to be displayed in the picker dropdown and it's causing the app to freeze. I am aware of the infinite scroll if it's viewing the content, where you fetch a limited size of the data from the server side and load more as the scroll reach to the bottom. But does it apply the same concept for a dropdown picker?
I am using the library #react-native-picker/picker and considering the behavior of the component I have no idea how to handle it.
I haven't done anything on my codes yet. Currently it's fetching all the listing from the server side and dump all the data in the picker.
usually it's best practice for large select list to create a modal screen which open up by clicking on the selectbox and there you provide a search box on top and show list using FlatList as it's good for large set of data and will not freeze your screen while rendering.
Check out this
This issue 2850 mentioned something may help you and to be clear there was a solution mentioned by M1K3Yio
please check the code using react-window in this link !!

How to make a dropdown filter like Amazon App in React Native?

So I'm trying to build a filter button that shows a screen below to let users customize the filter. I've searched for everything but couldn't find it. Does anyone have an example or suggestions? Ideally, It's supposed to work like Amazon App's filter. Something like this.

Autosuggest in react native

I have used react-native autosuggest, but it is not showing results according to what user has typed. No results are getting showed.Can you suggest me autosuggest wherein as soon as user types a text filtered results are shown and as user clicks on any element from autosuggest list then autosuggest gets closed I want it for both android and ios and also how to use it.
react-native-autocomplete-input is one of my favorite for the purpose