Skip to content

Commit

Permalink
fix(example): fix coordinates format as per GeoJson (#13718)
Browse files Browse the repository at this point in the history
* fix(example): fix coordinates format as per GeoJson

* Update data-types.js

Co-authored-by: Sascha Depold <sdepold@users.noreply.github.com>
  • Loading branch information
madguy02 and sdepold committed Nov 28, 2021
1 parent c7a0839 commit f9dec20
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/data-types.js
Original file line number Diff line number Diff line change
Expand Up @@ -802,7 +802,7 @@ class ARRAY extends ABSTRACT {
* DataTypes.GEOMETRY('POINT', 4326)
*
* @example <caption>Create a new point</caption>
* const point = { type: 'Point', coordinates: [39.807222,-76.984722]};
* const point = { type: 'Point', coordinates: [-76.984722, 39.807222]}; // GeoJson format: [lng, lat]
*
* User.create({username: 'username', geometry: point });
*
Expand All @@ -822,7 +822,7 @@ class ARRAY extends ABSTRACT {
* @example <caption>Create a new point with a custom SRID</caption>
* const point = {
* type: 'Point',
* coordinates: [39.807222,-76.984722],
* coordinates: [-76.984722, 39.807222], // GeoJson format: [lng, lat]
* crs: { type: 'name', properties: { name: 'EPSG:4326'} }
* };
*
Expand Down

0 comments on commit f9dec20

Please sign in to comment.