React-native-google-places-autocomplete: on focus

Created on 28 Aug 2017  路  5Comments  路  Source: FaridSafi/react-native-google-places-autocomplete

How can I know when a user has clicked on the search bar? on press seems to only be for when they hit search or done, but i need to take an action when they just click on the search bar.

Most helpful comment

Add onFocus inside textInputProps

textInputProps={{
    onFocus: () => yourCallback(),
}}

All 5 comments

Add onFocus inside textInputProps

textInputProps={{
    onFocus: () => yourCallback(),
}}

Do you know how to retrieve an event arg in onFocus function? Thank you

Were you able to find how? @MaxInMoon

textInputProps={{
onFocus: () => yourCallback(),
}}

Most Useful thank you

Still can't seem to retrieve the event arg in the onFocus function, anyone have any idea?

Was this page helpful?
0 / 5 - 0 ratings