leaflet-hash

linkable location hashes for leaflet

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
leaflet-hash
291280.2.19 years ago10 years agoMinified + gzip package size for leaflet-hash in KB

Readme

Leaflet-hash
Leaflet-hash lets you to add dynamic URL hashes to web pages with Leaflet maps. You can easily link users to specific map views.
Leaflet-hash

Demo

You can view a demo of leaflet-hash at mlevans.github.com/leaflet-hash/map.html.

Getting started

  1. Prepare a basic leaflet map. You can find instructions on Leaflet's quick-start guide.

  1. Include leaflet-hash.js.

  1. Once you have initialized the map (an instance of L.Map), add the following code:
```javascript
        // Assuming your map instance is in a variable called map
        var hash = new L.Hash(map);
    ```

Author

@mlevans

Contributors

@calvinmetcalf
@rsudekum
@tmcw
@yohanboniface

License

MIT License. See LICENSE for details.