Skip to content

Commit 2a1629d

Browse files
authored
Leaves a note about centering, to make getting started easier
1 parent 120585e commit 2a1629d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

docs/API.md

+1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ const Map = ReactMapboxGl({
4848
### Component Properties
4949
- **style** *(required)* : `String | Object` Mapbox map style, if changed, the style will be updated using `setStyle`.
5050
- **center** *(Default: `[ -0.2416815, 51.5285582 ]`)*: `Array<Number>` Center the map at the position at initialisation
51+
- Must be in longitude, latitude coordinate order (as opposed to latitude, longitude) to match GeoJSON (source: https://www.mapbox.com/mapbox-gl-js/api/#lnglat).
5152
- Re-center the map if the value change regarding the prev value or the actual center position [flyTo](https://www.mapbox.com/mapbox-gl-js/api/#Map.flyTo)
5253
- **zoom** *(Default: `[11]`)*: `Array<Number>` Zoom level of the map at initialisation wrapped in an array.
5354
- Check for reference equality between the previous value of zoom and the new one in order to update it or not.

0 commit comments

Comments
 (0)