Projection

An object with methods for projecting geographical coordinates of the world onto a flat surface (and back). See Map projection.

Methods

Method Returns Description
project(<LatLng> latlng) Point

Projects geographical coordinates into a 2D point.

unproject(<Point> point) LatLng

The inverse of project. Projects a 2D point into a geographical location.

Properties

Property Type Description
bounds LatLngBounds The bounds where the projection is valid

Defined projections

Leaflet comes with a set of already defined Projections out of the box:
Projection Description
L.Projection.LonLat Equirectangular, or Plate Carree projection — the most simple projection, mostly used by GIS enthusiasts. Directly maps x as longitude, and y as latitude. Also suitable for flat worlds, e.g. game maps. Used by the EPSG:3395 and Simple CRS.
L.Projection.Mercator Elliptical Mercator projection — more complex than Spherical Mercator. Takes into account that Earth is a geoid, not a perfect sphere. Used by the EPSG:3395 CRS.
L.Projection.SphericalMercator Spherical Mercator projection — the most common projection for online maps, used by almost all free and commercial tile providers. Assumes that Earth is a sphere. Used by the EPSG:3857 CRS.
v1.1.0
Props Wrld.Prop
Themes Wrld.themes
Heatmaps Wrld.Heatmap
Events Event objects
Services (Optional) WrldPoiApi