Skip to content

Commit ec333ab

Browse files
committed
update docs
1 parent 8a097a7 commit ec333ab

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -257,15 +257,16 @@ You will need to ensure that you have installed the following items through the
257257
2. add `./node_modules/react-native-mauron85-background-geolocation/ios/RCTBackgroundGeolocation.xcodeproj`
258258
3. In the XCode project navigator, select your project, select the `Build Phases` tab and in the `Link Binary With Libraries` section add **libRCTBackgroundGeolocation.a**
259259
4. add `UIBackgroundModes` **location** to `Info.plist`
260+
5. add `NSMotionUsageDescription` **App requires motion tracking** to `Info.plist` (required by ACTIVITY_PROVIDER)
260261

261262
For iOS before version 11:
262263

263-
5. add `NSLocationAlwaysUsageDescription` **App requires background tracking** to `Info.plist`
264+
6. add `NSLocationAlwaysUsageDescription` **App requires background tracking** to `Info.plist`
264265

265266
For iOS 11:
266267

267-
5. add `NSLocationWhenInUseUsageDescription` **App requires background tracking** to `Info.plist`
268-
6. add `NSLocationAlwaysAndWhenInUseUsageDescription` **App requires background tracking** to `Info.plist`
268+
6. add `NSLocationWhenInUseUsageDescription` **App requires background tracking** to `Info.plist`
269+
7. add `NSLocationAlwaysAndWhenInUseUsageDescription` **App requires background tracking** to `Info.plist`
269270

270271
## API
271272

@@ -370,8 +371,6 @@ Platform: iOS, Android
370371
Method will return all stored locations.
371372
This method is useful for initial rendering of user location on a map just after application launch.
372373

373-
NOTE: Returned locations does not contain location.id.
374-
375374
| Success callback parameter | Type | Description |
376375
|----------------------------|---------|--------------------------------|
377376
| `locations` | `Array` | collection of stored locations |
@@ -388,7 +387,6 @@ BackgroundGeolocation.getLocations(
388387
Platform: iOS, Android
389388

390389
Method will return locations, which has not been yet posted to server.
391-
NOTE: Locations does contain location.id.
392390

393391
| Success callback parameter | Type | Description |
394392
|----------------------------|---------|--------------------------------|
@@ -474,6 +472,9 @@ Unregister all event listeners for given event
474472
| `confidence` | `Number` | Percentage indicating the likelihood user is performing this activity. |
475473
| `type` | `String` | "IN_VEHICLE", "ON_BICYCLE", "ON_FOOT", "RUNNING", "STILL", |
476474
| | | "TILTING", "UNKNOWN", "WALKING" |
475+
476+
Note: Do not use location `id` as unique key in your database as ids will be reused when `option.maxLocations` is reached.
477+
477478
Note: Android currently returns `time` as type of String (instead of Number) [@see issue #9685](https://github.com/facebook/react-native/issues/9685)
478479

479480

0 commit comments

Comments
 (0)