Zoom levels - Leaflet - a JavaScript library for interactive maps
To understand how zoom levels work, first we need a basic introduction to geodesy.
When we represent the world at zoom level zero, it’s 256 pixels wide and high. When we go into zoom level one, it doubles its width and height, and can be represented by four 256-pixel-by-256-pixel images:
At each zoom level, each tile is divided in four, and its size (length of the edge, given by the tileSize option) doubles, quadrupling the area. (in other words, the width and height of the world is 256·2zoomlevel pixels):
In technical terms, the cylindrical projection that Leaflet uses is conformal (preserves shapes), but not equidistant (does not preserve distances), and not equal-area (does not preserve areas, as things near the equator appear smaller than they are).
setView(center, zoom), which also sets the map center
flyTo(center, zoom), like setView but with a smooth animation
zoomIn() / zoomIn(delta), zooms in delta zoom levels, 1 by default
zoomOut() / zoomOut(delta), zooms out delta zoom levels, 1 by default
setZoomAround(fixedPoint, zoom), sets the zoom level while keeping a point fixed (what scrollwheel zooming does)
fitBounds(bounds), automatically calculates the zoom to fit a rectangular area on the map