davidmfoley / react-router-modal

Simple modals for react-router 4
MIT License
153 stars 20 forks source link

bug fix: prevent Link onClick firing when modal is clicked #60

Open stellard opened 4 years ago

stellard commented 4 years ago

Hi.

I was having issue with the onClick handler for the Link being fired when I clicked the open modal.

This was especially a problem when I tried to use the closeModal function within the Modal since immediately after it was called, the Link onClick was also fired sending the router right back to the modal path.

Hope this helps other people.