google-maps-leaflet-tile-layer 3.0.0
Install from the command line:
Learn more about npm packages
$ npm install @eisberg-labs/google-maps-leaflet-tile-layer@3.0.0
Install via package.json:
"@eisberg-labs/google-maps-leaflet-tile-layer": "3.0.0"
About this version
Google Maps tile layer for react leaflet.
If you 👍 or use this project, consider giving it a ★, thanks! 🙌
Prerequisite is to have leaflet library already installed.
npm i --save [email protected] react-leaflet@^4.2.0
As for the google-maps-leaflet-tile-layer:
npm i --save @eisberg-labs/google-maps-leaflet-tile-layer
import {MapContainer, Marker} from 'react-leaflet';
import * as L from 'leaflet';
import "leaflet/dist/leaflet.css";
export const Basic = () => {
return (
<MapContainer id="map" zoom={10} center={[45, 16]} style={{
height: 300,
width: '100%',
position: 'relative', opacity: 1,
}}>
<GoogleLayer maxZoom={20}/>
</MapContainer>
)
}
Name | Type | Default | Description |
---|---|---|---|
subdomains | string[] |
['mt0', 'mt1', 'mt2'] |
If one subdomain is down, try another. |
MIT © Eisberg Labs