import { ConnectedRouter } from 'connected-react-router/immutable';
import { BrowserRouter as Router,} from 'react-router-dom';
i need to know difference between above both of them.
import { ConnectedRouter } from 'connected-react-router/immutable';
import { BrowserRouter as Router,} from 'react-router-dom';
i need to know difference between above both of them.
ConnectedRouter is to be used with Redux and can synchronize router state with a Redux store.
BrowserRouter is the 'standard' React router for the browser, to keep the UI in sync with the current URL.
The main difference in connected-react-router/immutable in is that history is stored in redux as immutable object so you can timetravel your history any time in the redux-life of the application.