Skip to content

Commit 7e85899

Browse files
committed
opencage: update README
1 parent ca19308 commit 7e85899

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

README.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,11 +171,19 @@ Note that you need an API key to use this service.
171171
### Constructor
172172

173173
```ts
174-
new L.Control.Geocoder.OpenCage(<String>key);
174+
new L.Control.Geocoder.OpenCage(<String>key, options);
175175
// or
176-
L.Control.Geocoder.opencage(<String>key);
176+
L.Control.Geocoder.opencage(<String>key, options);
177177
```
178178

179+
### Options
180+
181+
| Option | Type | Default | Description |
182+
| ---------------------- | ------ | ------------------------------------------------ | ------------------------------------------------------------------------------------ |
183+
| `serviceUrl` | String | `"https://api.opencagedata.com/geocode/v1/json"` | URL of the service |
184+
| `geocodingQueryParams` | Object | `{}` | Additional URL parameters (strings) that will be added to geocoding requests |
185+
| `reverseQueryParams` | Object | `{}` | Additional URL parameters (strings) that will be added to reverse geocoding requests |
186+
179187
## L.Control.Geocoder.LatLng
180188

181189
Parses basic latitude/longitude strings such as `'50.06773 14.37742'`, `'N50.06773 W14.37742'`, `'S 50° 04.064 E 014° 22.645'`, or `'S 50° 4′ 03.828″, W 14° 22′ 38.712″'`.

0 commit comments

Comments
 (0)