google_search_place 0.0.1 copy "google_search_place: ^0.0.1" to clipboard
google_search_place: ^0.0.1 copied to clipboard

outdated

Custom Google search places autocomplete widget for Android and iOS both. Use https://pub.dev/packages/google_search_place

google_search_place #

Add dependency into pubspec.yml #

dependencies:
  flutter:
    sdk: flutter
  google_search_place: <last-version>
  

AutoComplete TextField Widget code #

              SearchPlaceAutoCompletedTextField(
                    googleAPIKey: "",
                    controller: _searchPlaceController,
                    itmOnTap: (Prediction prediction) {
                      _searchPlaceController.text =
                          prediction.description ?? "";

                      _searchPlaceController.selection =
                          TextSelection.fromPosition(TextPosition(
                              offset: prediction.description?.length ?? 0));
                    },
                    getPlaceDetailWithLatLng: (Prediction prediction) {
                      _searchPlaceController.text =
                          prediction.description ?? "";

                      _searchPlaceController.selection =
                          TextSelection.fromPosition(TextPosition(
                              offset: prediction.description?.length ?? 0));

                      debugPrint("${prediction.lat} ${prediction.lng}");
              })
    

Customization Option #

You can customize a text field input decoration and debounce time

Screenshots #

[screenshots/sample.png]
4
likes
0
points
36
downloads

Publisher

unverified uploader

Weekly Downloads

Custom Google search places autocomplete widget for Android and iOS both. Use https://pub.dev/packages/google_search_place

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

dio, flutter, rxdart

More

Packages that depend on google_search_place