Skip to content

tristen/leaflet-interact-intent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Interact intent: a plugin for Leaflet.

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

Usage

<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>

Options

You can also pass an option to trigger interaction on click.

var map = L.map('map');
new leafletInteractIntent({
    clicktoplay: true
}).addTo(map)

Building

npm install && make

ProTip You may want to install watch so you can run watch make without needing to execute make on every change.

About

Interact with a map when a user intends it.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published