React-native-google-places-autocomplete: Can't select a item inside of ScrollView

Created on 31 Mar 2020  路  5Comments  路  Source: FaridSafi/react-native-google-places-autocomplete

I can't select a item inside of ScrollView. Sorry for the repetition question, but I can't find solutions for it.
My versions:
React-Native: "0.61.5",
React-native-google-places-autocomplete: "^1.4.1".

Example of me code:

<ScrollView
style={styles.styleContainer}
keyboardShouldPersistTaps="handled">
<GooglePlacesAutocomplete
placeholder="Your address"
minLength={1}
autoFocus={false}
returnKeyType={'default'}
keyboardAppearance={'light'}
listViewDisplayed={false}
fetchDetails={true}
renderDescription={row => row.description}
onPress={(data: any, details = null) => {
onChangeAddress(data.description);
}}
query={{
key: '***********',
}}
currentLocation={false}
debounce={200}
/>
</ScrollView>

Most helpful comment

@VTSingle
Please add keyboardShouldPersistTaps="handled" to your ScrollView component

All 5 comments

@VTSingle
Please add keyboardShouldPersistTaps="handled" to your ScrollView component

@nikolajordanovski That worked for me, thanks!

this worked for me too . thanks

@nikolajordanovski Thanks, it is wonderful solution.

Was this page helpful?
0 / 5 - 0 ratings