mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
D3321403 [NavigationExperimental][CleanUp]: Rename scene.navigationState to scene.route.
Summary: [public / experimental API breaking change] The data type of `scene.navigationState` is `NavigationRoute`. Rename `scene.navigationState` to `scene.route` to avoid confusion such as treating `scene.navigationState` as the actual global navigation state (type: NavigationState). Reviewed By: ericvicenti Differential Revision: D3331076 fbshipit-source-id: 3ed989cc8492d398cbeb1b12186459deb261d1fb
This commit is contained in:
committed by
Facebook Github Bot 4
parent
a45d025385
commit
fb5d0ff587
@@ -113,7 +113,7 @@ class NavigationAnimatedExample extends React.Component {
|
||||
_renderTitleComponent(/*NavigationSceneRendererProps*/ props) {
|
||||
return (
|
||||
<NavigationHeader.Title>
|
||||
{props.scene.navigationState.key}
|
||||
{props.scene.route.key}
|
||||
</NavigationHeader.Title>
|
||||
);
|
||||
}
|
||||
@@ -122,7 +122,7 @@ class NavigationAnimatedExample extends React.Component {
|
||||
return (
|
||||
<NavigationCard
|
||||
{...props}
|
||||
key={'card_' + props.scene.navigationState.key}
|
||||
key={'card_' + props.scene.route.key}
|
||||
renderScene={this._renderScene}
|
||||
/>
|
||||
);
|
||||
@@ -132,7 +132,7 @@ class NavigationAnimatedExample extends React.Component {
|
||||
return (
|
||||
<ScrollView style={styles.scrollView}>
|
||||
<NavigationExampleRow
|
||||
text={props.scene.navigationState.key}
|
||||
text={props.scene.route.key}
|
||||
/>
|
||||
<NavigationExampleRow
|
||||
text="Push!"
|
||||
|
||||
Reference in New Issue
Block a user