flutter_google_places_sdk
0.4.3, released 11 months ago by sparta.guru
Flutter plugin for Google Places SDK using native platform libraries.
What it does
Provides a Dart API to access Google Places autocomplete and other SDK features via the native libraries on each platform. It avoids HTTP requests, allowing API‑key restrictions on Android and iOS. Web support uses the Maps JavaScript API.
AI-written summary of version 0.4.3, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need Google Places autocomplete with native SDK integration
- You want to restrict your API key to specific apps
- You target multiple platforms (Android, iOS, web, desktop)
Skip it when
- Location restriction is required (not supported)
- You only need a simple HTTP‑based places request
Strengths
- Uses native SDK for better security
- Cross‑platform plugin covering mobile, web, and desktop
- Simple Dart‑only API
Weaknesses
- Location restriction not available
- Web usage requires enabling Maps JavaScript API
Setup
- Kind
- Plugin (native code)
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 7
Add the plugin to pubspec, provide your Google API key when creating FlutterGooglePlacesSdk. For web, enable Maps JavaScript API in Google Cloud. No additional native build steps beyond standard plugin setup.
import 'package:flutter/material.dart';
import 'package:flutter_google_places_sdk/flutter_google_places_sdk.dart';
void main() {
runApp(MaterialApp(
home: Scaffold(
body: Center(
child: ElevatedButton(
onPressed: () async {
final places = FlutterGooglePlacesSdk('my-key');
final predictions = await places.findAutocompletePredictions('Tel Aviv');
print('Result: $predictions');
},
child: Text('Predict and print to console'),
),
),
),
));
}Alternatives
Packages that do the same job and could replace flutter_google_places_sdk.
- google_places_sdk_plus
Flutter plugin for Google Places API using native SDKs on mobile and REST on web/desktop.
65Compare - google_maps_flutter_ios_sdk10
iOS implementation of the google_maps_flutter plugin using Google Maps SDK 10.
77Compare - google_maps_flutter_web
Web platform implementation of google_maps_flutter.
88Compare - amap_flutter_location
Flutter plugin for AMap Location SDK providing geolocation services on Android and iOS
36Compare