Skip to content

An extension to Leaflet that provide an enhanced markers in Leaflet

License

Notifications You must be signed in to change notification settings

dextercai/Leaflet.SpriteMarker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Leaflet.SpriteMarker

An extension to Leaflet that provide an enhanced markers creater

Explain

We CAN NOT create the markers with a map file which contains several icons like that in Google Map APIs. This extension will help to create it simplely.

Example

var MarkerOption = {
url: 'example.png',
size: {width:40, height:38},
origin: {x:0, y:48},
anchor: {x:20, y:18}
};
var SpriteMarker = L.Marker.SpriteMarker([0,0],MarkerOption);
SpriteMarker.setTo(map);

There are examples at the examples folder like below. ./examples/SpriteMarkerExample.html

About

An extension to Leaflet that provide an enhanced markers in Leaflet

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published