mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-02-07 23:03:19 +08:00
docs(background-geolocation): config method, example fix (#478)
This commit is contained in:
parent
efa222fb55
commit
61716467df
@ -188,13 +188,11 @@ export interface Config {
|
|||||||
|
|
||||||
* }, (error) => {
|
* }, (error) => {
|
||||||
* console.log('BackgroundGeolocation error');
|
* console.log('BackgroundGeolocation error');
|
||||||
* }, {
|
* }, config);
|
||||||
* //options
|
|
||||||
* });
|
|
||||||
*
|
*
|
||||||
* // Turn ON the background-geolocation system. The user will be tracked whenever they suspend the app.
|
* // Turn ON the background-geolocation system. The user will be tracked whenever they suspend the app.
|
||||||
* BackgroundGeolocation.start();
|
* BackgroundGeolocation.start();
|
||||||
* }
|
* })
|
||||||
*
|
*
|
||||||
* // If you wish to turn OFF background-tracking, call the #stop method.
|
* // If you wish to turn OFF background-tracking, call the #stop method.
|
||||||
* BackgroundGeolocation.stop();
|
* BackgroundGeolocation.stop();
|
||||||
@ -211,13 +209,14 @@ export class BackgroundGeolocation {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Configure the plugin.
|
* Configure the plugin.
|
||||||
* Success callback will be called with one argument - Location object, which tries to mimic w3c Coordinates interface.
|
*
|
||||||
|
* @param {Function} Success callback will be called when background location is determined.
|
||||||
|
* @param {Function} Fail callback to be executed every time a geolocation error occurs.
|
||||||
|
* @param {Object} An object of type Config
|
||||||
|
*
|
||||||
|
* @return Location object, which tries to mimic w3c Coordinates interface.
|
||||||
* See http://dev.w3.org/geo/api/spec-source.html#coordinates_interface
|
* See http://dev.w3.org/geo/api/spec-source.html#coordinates_interface
|
||||||
* Callback to be executed every time a geolocation is recorded in the background.
|
* Callback to be executed every time a geolocation is recorded in the background.
|
||||||
*
|
|
||||||
* Fail callback to be executed every time a geolocation error occurs.
|
|
||||||
*
|
|
||||||
* Options a json object of type Config
|
|
||||||
*/
|
*/
|
||||||
@Cordova({
|
@Cordova({
|
||||||
sync: true
|
sync: true
|
||||||
|
Loading…
Reference in New Issue
Block a user