File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -116,6 +116,26 @@ class HomeScreen extends React.Component {
116
116
}
117
117
```
118
118
119
+ * Going back from a specific screen*
120
+
121
+ Consider the following navigation stack history:
122
+ ``` ...
123
+ navigation.navigate(SCREEN_KEY_A);
124
+ ...
125
+ navigation.navigate(SCREEN_KEY_B);
126
+ ...
127
+ navigation.navigate(SCREEN_KEY_C);
128
+ ...
129
+ navigation.navigate(SCREEN_KEY_D);
130
+ ```
131
+
132
+ Now you are on * screen D* and want to go back to * screen A* (popping D, C, and B).
133
+ Then you need to supply a key to goBack * FROM* :
134
+
135
+ ```
136
+ navigation.goBack(SCREEN_KEY_B) // will go to screen A FROM screen B
137
+ ```
138
+
119
139
## ` dispatch ` - Send an action to the router
120
140
121
141
Use dispatch to send any navigation action to the router. The other navigation functions use dispatch behind the scenes.
You can’t perform that action at this time.
0 commit comments