ViewState
The visible part of the map.
This is an interface exported by @mapcairn/core, checked against version 0.2.0.
Signature
import type { ViewState } from "@mapcairn/core";
interface ViewState
Properties
bearing
readonly bearing: number;
Degrees clockwise from north that the top of the map points to, in the range [0, 360).
center
readonly center: LatLng;
The position at the middle of the map.
zoom
readonly zoom: number;
The normalised zoom: the 256 px tile convention, the same for every engine.
Remarks
zoom is always the normalised zoom: the 256 px tile convention
used by OpenStreetMap tile numbering. MapLibre counts 512 px tiles, so
its adapter subtracts one on the way in and adds one on the way out.
bearing is degrees clockwise from north, in the range [0, 360).