Passing props to react-redux container component

后端 未结 4 1738
温柔的废话
温柔的废话 2021-01-30 05:08

I have a react-redux container component that is created within a React Native Navigator component. I want to be able to pass the navigator as a prop to this container component

4条回答
  •  太阳男子
    2021-01-30 05:35

    mapStateToProps and mapDispatchToProps both take ownProps as the second argument.

    [mapStateToProps(state, [ownProps]): stateProps] (Function):
    [mapDispatchToProps(dispatch, [ownProps]): dispatchProps] (Object or Function):
    

    For reference

提交回复
热议问题