Interact with a map when a user intends it.
UNLICENSE License
This plugin attempts to enable map interaction when a user wants to interacts with a map. Page scrolling should work without unintentionaly zooming when a map is reached on a page.
Want to see it in action? Check out the demo
<link href='leaflet-interact-intent.css' rel='stylesheet' />
<script src='leaflet-interact-intent.js'></script>
<script>
var map = L.map('map');
new leafletInteractIntent().addTo(map)
</script>
You can also pass an option to trigger interaction on click.
var map = L.map('map');
new leafletInteractIntent({
clicktoplay: true
}).addTo(map)
npm install && make
ProTip You may want to install watch
so you can run watch make
without needing to execute make on every change.