Last updated:
0 purchases
my location library21
My Locaton
Features #
this Library provides the functionality to extract the current location and stream it to our endpoint. You can find the library at this URL: https://pub.dev/packages/my_location_library21.
Getting started #
Usage #
1,Install the package:
$ flutter pub add my_location_library21
copied to clipboard
2.Import the package in your Dart file:
import 'package:my_location_library21/my_location_library21.dart';
copied to clipboard
3,Call function and initialize
//call function
Future<void> _getCurrentLocation() async {
LocationData? locationData = await LocationService.getCurrentLocation();
print('Current Location Latitude: ${_currentLocation.latitude}');
print('Current Location Longitude: ${_currentLocation.longitude}');
}
// initialized the function
void initState() {
super.initState();
_getCurrentLocation();
}
copied to clipboard
Additional information #
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.