react-native-google-maps-plus
v2.0.0
Published
React Native wrapper for Android & iOS Google Maps SDK with Street View support
Maintainers
Readme
Features
- Map view and Street View panorama
- Markers with SVG icons, rendered with lunasvg
- Advanced Markers with pins and glyphs
- Polylines, polygons, circles, heatmaps, KML layers and URL tile overlays
- Map styles, map IDs, dark mode, traffic, transit and indoor maps
- Camera control and snapshots
- Location updates, heading and permissions
Requirements
| | Minimum | | ------------ | ---------------------------------------- | | React Native | 0.87, New Architecture | | iOS | 16 | | Android | API 26, Kotlin 2.3 | | Expo | Development build with the config plugin |
Installation
yarn add react-native-google-maps-plus react-native-nitro-modulesThen set up the Google Maps SDKs and your API keys for iOS and Android, see the installation guide.
Usage
import { GoogleMapsView } from 'react-native-google-maps-plus';
export default function App() {
return (
<GoogleMapsView
style={{ flex: 1 }}
mapOptions={{
camera: {
center: { latitude: 37.7749, longitude: -122.4194 },
zoom: 12,
},
}}
markers={[
{
id: 'ferry-building',
coordinate: { latitude: 37.7955, longitude: -122.3937 },
},
]}
/>
);
}Overlays are props, callbacks report what the user does and the ref moves the camera. See Usage and the examples.
Documentation
- Installation
- Usage
- Upgrading from 1.x
- SVG markers
- Advanced markers
- Troubleshooting
- Limitations
- API reference
- llms.txt for AI tools
Contributing
License
MIT
