another-google-map-react
v1.1.29
Published
Google Map react component. Supports GeoJSON overlay
Downloads
15
Maintainers
Readme
another-google-map-react
Made with create-react-library
Install
npm install --save another-google-map-react
Usage
import React from 'react'
import { GoogleMap, GeoJsonLayer } from 'another-google-map-react'
const GOOGLE_MAP_LOADER_URL = `https://maps.googleapis.com/maps/api/js?v=beta&libraries=places`
<GoogleMap
googleMapOptions={{
center: { lat: -34, lng: 151 },
zoom: 10,
mapTypeId: 'roadmap',
streetViewControl: false
}}
style={{}}
onClick={(latLng) => alert(JSON.stringify(latLng))}
onBoundsChanged={(boundingBox) => {}}
gooleMapLoaderUrl={GOOGLE_MAP_LOADER_URL}
googleMapRef={(map) => {}}
></GoogleMap>
License
MIT © maxim75