* [flow] Remove "any" type from NavigationComponent
"any" cripples the typechecker, so it's best to avoid. It was introduced in #3392, but I don't think the intention was to keep it there.
* [flow] Remove `any` type from `createNavigator` return
And use objects with spread sub-types instead of unions for `React$ComponentType` type param
This really is not ideal but it's an upstream bug on react-native Android
that we can't work around. Users may experience other unexpected behavior as a
result of this upstream bug.
Previously we had been emiting an action event with a null state when the router handles the action by returning null from getStateForAction.
- Fixes the case of null state getting emitted
- Renames a few things for clarity
- Refactors conditionals to read easier
- Comments to explain intent
* 3127: Fixed gestureDirectionInverted variable declaration and condition in onPanResponderMove method in regards to swipe back action in RTL mode.
* - 4118: Put axis check first;
- Fixed default BackButton mask in RTL mode.
“reset” is not a NavigationAction anymore.
The correct fix, for v3, to this is to navigate to the first screen inside the stack. With the less-pushy navigate behavior in v2, this will result in the first route getting selected if you specify it by routeName.
* Use Array.prototype.findIndex instead of map => indexOf
Creating a new array and iterating over all the routes is inefficient compared to findIndex, which does not create a new array and exits as soon as it finds a match. Since the indexOf method is used extensively this should provide a minor performance improvement
* reverted yarn.lock edits
* don’t use private global
* add missing method ‘getParam’ to navigation screen prop
* correct return type for ‘withNavigation’
* add usage of `getParam` method