React-router and iframe, browser history

I came to an anyoing problem. So I have a component in react

as well as using react-router

. Everything works almost perfectly. This component has a list of items, when you click one, it clicks url on iframe[src={url}]

. And this is where the problem comes in if I click on multiple items and then click on the previous page / back button, instead of going to the previous page, it just shows the previous iframe url that was clicked on the iframe.

What should I do in this situation?

@I use react-router-dom v4

+3


source to share





All Articles