如何一起传递 redux 道具和导航参数?

How to pass redux props and navigation parameters together?

我已经成功传递了如下的react native导航参数:

PageOne = ({ navigation, route }) => {
const { itemId, otherParam } = route.params;
...
}

并且我已经完成传递 redux 道具以使用 redux 操作,如下所示:

PageTwo = (props) => {

}

如何将参数和道具放在一个组件中?

非常感谢您的帮助!

这应该有效

Page = (props) => {
const { navigation, route } = props
const { itemId, otherParam } = route.params;
...
}

您可以像这样组合它们:

PageOne = ({ navigation, route, reduxParam1,reduxParam2 }) => {
const { itemId, otherParam } = route.params;
}

或者你也可以这样使用

PageOne = (props) => {
const { itemId, otherParam } = props.route.params;
}