Ability to get more information than just coordinates from 'didTap' event
See original GitHub issueI’m using the following code to capture events when a user taps on a marker which I’m setting with the “addMarker” method
CapacitorGoogleMaps.addListener("didTap", (value) => { console.log('didTap fired', value.result); });
On ios, the resulting value
in the function above has the following structure:
{ result: { coordinates: { latitude: number, longitude: number } } }
On android, I get an entirely different object in the value
:
{ location:{ latitude: number, longitude: number }, name: string, snippet: string }
Is there any way to expose information other than just latitude and longitude on both ios and android? It would also be incredibly useful if we could expose information about the tapped marker beyond just what is visible in the settings as I’d like to act on a unique identifier other than the gps coordinates. Also curious if the plan is to return a consistent object structure across both ios and android.
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (5 by maintainers)
Top GitHub Comments
I went ahead and approved this as I didn’t see any code smells and it seemed like a fairly lightweight change. That said, I do come from a .NET background primarily so take my approval with a grain of salt.
On Thu, Jan 28, 2021 at 10:37 AM Hemang Kumar notifications@github.com wrote:
@quaz579 Sure, sounds good. What time zone are you in btw? feel free to shoot an email at hemangsk@gmail.com