class City extends Component {
componentDidMount() {
console.log(
this
.props.userInfo)
console.log(
this
.props.userInfoActions)
}
render() {
return
(
<div>
<Header />
</div>
)
}
}
function
mapStateToProps(state) {
return
{
userInfo: state.userInfo
}
}
function
mapDispatchToProps(dispatch) {
return
{
userInfoActions: bindActionCreators(userInfoActionsFromOtherFile,dispatch)
}
}
export
default
connect(mapStateToProps, mapDispa