标签: reactjs react-native react-navigation
我遵循了本指南https://reactnavigation.org/docs/en/navigating-without-navigation-prop.html来进行导航而不使用导航道具。我想知道是否可以将getParam添加到NavigationService来像navigation.getParam一样使用它。
getParam
NavigationService
navigation.getParam
谢谢
答案 0 :(得分:0)
您可以使用onNavigationStateChange
onNavigationStateChange
https://reactnavigation.org/docs/en/screen-tracking.html