Skip to content
This repository has been archived by the owner on Feb 17, 2022. It is now read-only.

laurencedorman/google-maps-api-loader

Repository files navigation

Google Maps API Loader

DEPRECATED 18/02/2021

Use the official googlemaps/js-api-loader library instead.


npm travis Dependency Status devDependency Status

Provides a convenient wrapper for the Google Maps API, allowing it to be called in the promise syntax.

Installation

$ npm install --save google-maps-api-loader

Usage

var GoogleMapsApiLoader = require('google-maps-api-loader');

GoogleMapsApiLoader({
        libraries: ['places'],
        apiKey: 'your-api-key' // optional
    })
    .then(function(googleApi) {
        var autocomplete = new googleApi.maps.places.AutocompleteService();
    }, function(err) {
        console.error(err);
    });

License

MIT

About

A promise wrapper for loading the Google Maps API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •