I have used the location plugin in the flutter, I can get the latitude
and longitude
only. How to get the full ad
`
import 'package:flutter/material.dart';
import 'package:geocoder/geocoder.dart';
import 'package:geolocator/geolocator.dart';
_getLocation() async {
GeolocationStatus geolocationStatus = await
Geolocator().checkGeolocationPermissionStatus();
Position position = await Geolocator()
.getCurrentPosition(desiredAccuracy: LocationAccuracy.high);
debugPrint('location: ${position.latitude}');
final coordinates = new Coordinates(position.latitude, position.longitude);
debugPrint('coordinates is: $coordinates');
var addresses =
await Geocoder.local.findAddressesFromCoordinates(coordinates);
var first = addresses.first;
// print number of retured addresses
debugPrint('${addresses.length}');
// print the best address
debugPrint("${first.featureName} : ${first.addressLine}");
//print other address names
debugPrint(Country:${first.countryName} AdminArea:${first.adminArea} SubAdminArea:${first.subAdminArea}");
//print more address names
debugPrint(Locality:${first.locality}: Sublocality:${first.subLocality}");
}
`