You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, when the user clicks on a marker, nothing happens. I know I can make a Popup appear if I just write it inside the returning JSX, without any conditional rendering. I also tested the boolean values showPopup and selectedMarker, to make sure it wasn't a pure logic problem.
To Reproduce
Steps to reproduce the behavior:
Install @urbica/react-map-gl and mapbox-gl
Replicate my code, changing the useGeoMap hook to some simple state management
Run the App
See error
Expected behavior
I expected a Popup to appear when the user clicks on a Marker, based on the code above.
Additional context
The useGeoMap hook is nothing but externalized state management for the markers, since I am adding them outside of the MarkerControl component. Any additional requested code will be provided as soon as requested.
Thanks in advance for any help provided! :)
The text was updated successfully, but these errors were encountered:
I am trying to implement a Popup functionality when a user clicks on the markers on the Map. This is the relevant part of the code:
App.tsx
MarkerControl.tsx
However, when the user clicks on a marker, nothing happens. I know I can make a Popup appear if I just write it inside the returning JSX, without any conditional rendering. I also tested the boolean values
showPopup
andselectedMarker
, to make sure it wasn't a pure logic problem.To Reproduce
Steps to reproduce the behavior:
Expected behavior
I expected a Popup to appear when the user clicks on a Marker, based on the code above.
Screenshots
Popup not popping up :(
Desktop (please complete the following information):
Additional context
The useGeoMap hook is nothing but externalized state management for the markers, since I am adding them outside of the MarkerControl component. Any additional requested code will be provided as soon as requested.
Thanks in advance for any help provided! :)
The text was updated successfully, but these errors were encountered: