This might not be next.js related, but I am using it in a next.js app so I am trying here. Let me know if I should try elsewhere.
I am making an app that has an image that fills the screen .This image is a "map" and when the user clicks different area of the map, different boxes are displayed.
I found two packages that helped me out. react-image-map and react-popup.
What I want now is to make components for the different boxes that should appear when clicked and display these. Is there a way to inject the Component at runtime into the popup box/div when the uses clicks the area?
Hope this makes sense...
Source code in next message