Open smashercosmo opened 9 years ago
+1
:+1:
Slightly related, we end up having a huge amount of duplicated state between the redux-router part of our Redux state and the rest of our Redux state. We're sort of in this position because we are using combineReducers
for modularity, but that means any routable-bits of our overall application state have to be duplicated between the redux-router state and the rest of our Redux application state. It would be nice to see a more cohesive approach to this.
:+1:
+1
Just out of curiosity - would something like simply removing:
this.props.params
this.props.location
this.props.history
this.props.routes
this.props.route
this.props.routeParams
Be a solution? Ultimately tucking all those props into the router
itself? Changes like this are definitely braking imo - that being said - any thoughts?
It seems to me that there is some overhead with keeping router state. When using redux-react-router we have router state in our app state and also in the component's props. So we have
this.props.router.location this.props.router.component this.props.router.params this.props.router.routes
this.props.params this.props.location this.props.history this.props.routes this.props.route this.props.routeParams
Is there any way to reduce number of props kept?