UNPKG

476 BHTMLView Raw
1---
2layout: example.html
3title: Mousewheel/Trackpad Zoom
4shortdesc: Restrict wheel/trackpad zooming to integer zoom levels.
5docs: >
6 By default, the `ol.interaction.MouseWheelZoom` can leave the map at
7 fractional zoom levels. If instead you want to constrain wheel/trackpad
8 zooming to integer zoom levels, set <code>constrainResolution: true</code>
9 when constructing the interaction.
10tags: "trackpad, mousewheel, zoom, interaction"
11---
12<div id="map" class="map"></div>