Home > @yext/search-ui-react > getUserLocation
Retrieves user's location using navigator.geolocation API.
Signature:
export declare function getUserLocation(geolocationOptions?: PositionOptions): Promise<GeolocationPosition>;
Parameter | Type | Description |
---|---|---|
geolocationOptions | PositionOptions |
Returns:
Promise<GeolocationPosition>