We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Because my current code does not work, however if I use only a console.log within onPlaceSelected the selection in the input is maintained correctly.
<Controller name="location" render={({ field, fieldState: { error } }) => { return ( <div> <span style={{ color: 'black' }}>Location</span> <Input fullWidth inputComponent={({ inputRef, onFocus, onBlur, ...props }) => ( <Autocomplete apiKey="..." {...props} onPlaceSelected={(selected) => { const lat = selected.geometry.location.lat(); const lng = selected.geometry.location.lng(); field.onChange({ lat, lng, formatted_address: selected.formatted_address, }); }} /> )} /> </div> ); }} />
Gif error:
The text was updated successfully, but these errors were encountered:
First idea: did you checked if your Input or Controller component is rerendered for some reason, so it resets the value?
Input
Controller
Sorry, something went wrong.
No branches or pull requests
Because my current code does not work, however if I use only a console.log within onPlaceSelected the selection in the input is maintained correctly.
Gif error:
The text was updated successfully, but these errors were encountered: