watchPosition method

int watchPosition(
  1. PositionCallback successCallback, [
  2. PositionErrorCallback? errorCallback,
  3. PositionOptions options
])

The watchPosition() method of the Geolocation interface is used to register a handler function that will be called automatically each time the position of the device changes. You can also, optionally, specify an error handling callback function.

Implementation

external int watchPosition(
  PositionCallback successCallback, [
  PositionErrorCallback? errorCallback,
  PositionOptions options,
]);