【发布时间】:2018-07-01 05:49:45
【问题描述】:
我注意到下面的navigate 不会在将 Redux 状态传递给另一个组件后更新它,即使 Redux 数据已更新。
navigation.navigate('anotherComponent', { firstname, lastname, loading, onRefresh });
在anotherComponent,
this.props.navigation.state.params
这可以正常工作,但一旦从前一个组件接收到状态,它就不会更新 Redux 状态值。更新 Redux 状态不会改变 anotherComponent 中的任何内容。
如何使这个连接到 Redux,以便 anotherCompoenet 在 Redux 更新时实际更新数据?
【问题讨论】:
标签: react-native redux react-native-navigation