I created a custom React hook using the window.navigator.geolocation object and the getCurrentPosition() method. This hook returns the current location of the user.
mariechanaron.github.io/geo-locator/
- Indicate the hemisphere
- Indicate the latitude and longitude coordinates.
React version 18.2.0