![Lintly](https://lintly.com/gh/maykinmedia/lazymaps/badge.svg)
![Sauce Test Status](https://saucelabs.com/browser-matrix/lazymaps.svg)
lazymaps
Lazy loading, easy to use wrapper around the Google Maps API.
Install
Install with npm
$ npm i lazymaps --save
Usage
Code examples in es6, library is es5 compatible.
See doc for full API documentation.
HTML
<div class="map" data-coordinates="52.3766882,4.8855208,17" data-zoom="15"></div>
JS: Creating a single map
import GMap from 'lazymaps';
let node = document.querySelector('.map');
let apiKey = 'ABC'
new GMap(this.node, apiKey);
JS: Create multiple maps using a selector
import GMap from 'lazymaps';
let apiKey = 'ABC'
lazymaps('.map', apiKey);
Running tests
$ gulp lint // Check for linting errors
$ gulp test // Run the tests
Contributing
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Author
Maykin Media
License
Copyright © 2017 Maykin Media
Licensed under the MIT license.