
Research
Supply Chain Attack on Axios Pulls Malicious Dependency from npm
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.
react-native-maps-google
Advanced tools
This package provides a React Native compatible, Google Maps UI component which runs on iOS and Android using the same JavaScript API.

npm install --save react-native-maps-google
.xcodeproj file in the ios directory of your React
Native project.$(PROJECT_DIR)/../node_modules/react-native-maps-google/ios_modules/GoogleMaps-1.11.1/Frameworks to the framework
search path list and make sure it is set to recursive.$(SRCROOT)/../node_modules/react-native-maps-google to the header
search path list and make sure that it is also set to recursive.node_modules/react-native-maps-google/ios in Finder and locate the PPTMapView.xcodeproj package.
Drag this file into the XCode project navigator. You can keep this in the Libraries group along with all the other
React Native packages.PPTMapView.xcodeproj tree and select GoogleMapsApi.plist - drag this into the group which contains
your AppDelegate.h and AppDelegate.m files; this group is usually named after your app. When prompted ensure that
Copy Items if Needed is deselected when prompted, this will prevent this file from being committed into source
control. Open up the file and enter your Google API key into the value column of the row named API Key.AppDelegate.m and add #import "PPTGoogleMapProvider.h" at the top of the file. Then add
[PPTGoogleMapProvider provideAPIKey]; somewhere in the application method, ideally at the top.Google Maps SDK group in PPTMapView.xcodeproj, drag these packages into the Libraries group of
your React Native project and ensure that Copy Items if Needed is deselected when prompted.GoogleMaps.bundle) and drag them
into this build phase.+ button and search for libPPTMapView.a (it should be in the Workspace folder). Select libPPTMapView.a and click the Add button. Scroll back up to the top of the list and double check that it was added.Cmd+R and make sure the app runs!android directory in your React Native project.settings.gradle. Replace the line in the script
which states include ':app' with include ':app', ':pptmapview' (or append ':pptmapview' to the end of the
include statement if you're already including other modules).settings.gradle:project(':pptmapview').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-maps-google/android/library')
app module build.gradle file and add the following line to the end of your dependancies section:compile project(path: ':pptmapview')
MainActivity class and import the following package:import xyz.plan.android.pptmapview.PPTGoogleMapPackage;
.addPackage(new MainReactPackage()),
add the following line below:.addPackage(new PPTGoogleMapPackage())
pptmapview package in your project explorer and then expand the manifests directory. Open up the
AndroidManifset.xml and find the node with the key com.google.android.geo.API_KEY. Enter your Google API key
into the android:value property and save the file. This file will be kept out of source control so it is safe to
store the API key in here.Ctrl+R and make sure the app runs!Require the UI component in the component you're wanting to display a map in:
import GoogleMap from 'react-native-maps-google';
Include the following JSX in your render method:
<GoogleMap />
You will need to style the component appropriately so that it is visible, just like any other React Native view component.
There are a number of options for the map view which let you customise its layout and UI options. These are specified as JSX parameters like so:
<GoogleMap
cameraPosition={{auto: true, zoom: 10}}
showsUserLocation={true}
scrollGestures={true}
zoomGestures={true}
tiltGestures={true}
rotateGestures={true}
consumesGesturesInView={true}
compassButton={true}
myLocationButton={true}
indoorPicker={true}
allowScrollGesturesDuringRotateOrZoom={true}
/>
cameraPosition - The map view camera position. You can set auto to true and specify a zoom level
or you can pass the latitude, longitude and zoom level to manually position the camera.showsUserLocation - If true the app will ask for the user's location and focus on it. Default value is false.scrollGestures - Controls whether scroll gestures are enabled (default) or disabled.zoomGestures - Controls whether zoom gestures are enabled (default) or disabled.tiltGestures - Controls whether tilt gestures are enabled (default) or disabled.rotateGestures - Controls whether rotate gestures are enabled (default) or disabled.consumesGesturesInView - Controls whether gestures by users are completely consumed by the GMSMapView when gestures
are enabled (default YES).compassButton - Enables or disables the compass.myLocationButton - Enables or disables the My Location button.indoorPicker - Enables (default) or disables the indoor floor picker.allowScrollGesturesDuringRotateOrZoom - Controls whether rotate and zoom gestures can be performed off-center and
scrolled around (default YES).Map markers can be set by passing an array of objects which describe them. The markers can be the stock Google variety,
or you can pass a reference to an image to customise them. The stock Google marker color can be customized by setting
the hexColor property (7 characters, including a # prefix). It's also possible to add metadata to the marker, simply add
a meta parameter to the marker object. All markers require a unique identifier string, these should be formatted in a
similar way to an id tag in HTML. This metadata is returned when an event which affects the marker is fired such
as didTapMarker. Markers are specified using a JSX parameter:
<GoogleMap
markers={[
{
id: 'marker-100',
latitude: 51.5072,
longitude: -0.1275
},
{
id: 'marker-101',
latitude: 53.2031,
longitude: -1.5621,
icon: require('./images/my-custom-marker.png')
},
{
id: 'marker-102',
latitude: 21.7342,
longitude: -5.7350,
meta: {
foo: 'bar'
}
},
{
id: 'marker-103',
latitude: 56.2031,
longitude: -1.7621,
hexColor: '#00abff'
},
]}
/>
Event listeners can be attached to the map in the form of a callback. These are specified as a JSX parameter like so:
<GoogleMap
didTapMarker:{function(event) {
console.log(event.name);
}}
/>
The following events listeners are available:
didChangeCameraPosition - Called repeatedly during any animations or gestures on the map (or once, if the camera
is explicitly set). This may not be called for all intermediate camera positions. It is always called for the final
position of an animation or gesture - iOS and Android.idleAtCameraPosition - Called when the map becomes idle, after any outstanding gestures or animations have
completed (or after the camera has been explicitly set) - iOS Only.didTapAtCoordinate - Called after a tap gesture at a particular coordinate, but only if a marker was not tapped
didLongPressAtCoordinate - Called after a long-press gesture at a particular coordinate - iOS and Android.didTapMarker - Called after a marker has been tapped - iOS and Android.didTapOverlay - Called after an overlay has been tapped - iOS Only.didBeginDraggingMarker - Called when dragging has been initiated on a marker - iOS and Android.didEndDraggingMarker - Called after dragging of a marker ended - iOS and Android.didDragMarker - Called while a marker is dragged - iOS and Android.didTapMyLocationButtonForMapView - Called when the My Location button is tapped - iOS and Android.An object is returned with details about the event, these typically look like:
{
id: 'marker-102',
name: "didTapMarker",
data: {
latitude: 21.7342,
longitude: -5.7350,
meta: {
foo: 'bar'
}
}
}
Thank you for considering contributing to this package! The contribution guide can be found here.
To the maintainer of this fork:
If you discover a security vulnerability within this package, please send an e-mail to github@plan.xyz. All security vulnerabilities will be promptly addressed.
To the original author:
If you discover a security vulnerability within this package, please send an e-mail to software@pod-point.com. All security vulnerabilities will be promptly addressed.
FAQs
Google Maps UI component for React Native http://plan.xyz
The npm package react-native-maps-google receives a total of 22 weekly downloads. As such, react-native-maps-google popularity was classified as not popular.
We found that react-native-maps-google demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.

Security News
TeamPCP is partnering with ransomware group Vect to turn open source supply chain attacks on tools like Trivy and LiteLLM into large-scale ransomware operations.