Function reprojectGeoJSON

Reprojects the coordinates of each of the GeoJSON object's vertices between the object's CRS to the target CRS.

  • Parameters

    • geojson: AllGeoJSON

      GeoJSON Feature, FeatureCollection, Geometry or GeometryCollection.

    • crs: string

      CRS in which the vertices of the GeoJSON object are written.

    • target: string

      The desired CRS to reproject the vertices of the GeoJSON object to.

    Returns AllGeoJSON

    GeoJSON Feature, FeatureCollection, Geometry or GeometryCollection in the target CRS.