brh55/react-native-open-maps

How to drop a Marker Pin?

95deepan opened this issue ยท 11 comments

I could open the map application using this react-native-open-maps module, but after opening the location suddenly gets changed to the user's current location. How to sustain the view or is there any possibility to add a marker to the opened location?

Same here, it was working before the new update. Now on Mobile Maps (tested on Android) it opens the location "Pin", meanwhile in the browser maps it opens my current position.

Same here, it was working before the new update. Now on Mobile Maps (tested on Android) it opens the location "Pin", meanwhile in the browser maps it opens my current position.

Same here

brh55 commented

Are you guys experiencing this issue only on Google Maps? It seems that using a q parameter for Google maps is most likely going to redirect to a "Pin", but doesn't seem to be the case in Apple Maps.

Any update about this?

brh55 commented

@mumapu fix in 0.2.0

@brh55 I'm still seeing this issue in 0.3.3 where a marker is not shown. It opens the maps fine and shows the correct area but the marker is not displayed.

Using the code like this:

openMap({ latitude: 37.865101, longitude: -119.538330 });

ivnnv commented

I can confirm pin is NOT showing in Apple Maps on iOS but it correctly showing in Google Maps on Android. Also using 0.3.3

brh55 commented

For appl

@brh55 I'm still seeing this issue in 0.3.3 where a marker is not shown. It opens the maps fine and shows the correct area but the marker is not displayed.

Using the code like this:

openMap({ latitude: 37.865101, longitude: -119.538330 });

Try providing a query parameter to see a marker/pin on Apple maps, it's an odd requirement on Apple maps. Sort of the biggest difference between the two platforms, so the behavior is going to act a little different, check readme. If there is a different expected behavior that makes sense, we can find a way to accommodate!

Any Solutions> I am facing the exact same issue for google maps on android & IOS. The Marker is not shown?

onPress={openMap(Platform.OS === 'ios' ?
{
latitude: 37.865101,
longitude: -119.538330,
query: 'Yosemite Trails',
zoom: 16,
provider: 'apple'
} :
{
query: '37.865101,-119.538330',
zoom: 16,
provider: 'google'
}
)}

same issues to me, really dont know why?