Can we use Openstreetmap in Flutter or can we only use Google Maps? I wanted to get another way to display a Map. Cause when using googlemaps api key they need to know a Credit Card and i dont have one.
Openstreetmap API is an open-source initiative that generates world map data and makes them available for free. This means you don't have to pay anything to request data from its database. In fact, you'll even have access to the entire database of Openstreetmap, which isn't so in paid APIs.
map() Iterable<T> map<T> (T Function(String) f) Returns a new lazy Iterable with elements that are created by calling f on each element of this Iterable in iteration order. This method returns a view of the mapped elements.
To use Google Maps in your Flutter app, you need to configure an API project with the Google Maps Platform, following the Maps SDK for Android's Using API key, Maps SDK for iOS' Using API key, and Maps JavaScript API's Using API key.
You can use the below plugin. An example is included in the repository.
https://github.com/apptreesoftware/flutter_map
Pub.dev link:
https://pub.dev/packages/flutter_map
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With