fix: fix navigationOptions type in NavigationScreenConfig<Options> (#5962)

- `NavigationScreenProp<NavigationRoute>` is the type of `navigation` property which contains `state` and such. This is not applicable to `navigationOptions` at all.
This commit is contained in:
Chau Tran
2019-06-04 03:12:41 -05:00
parent 5e522358c5
commit 6ef8ce0fd5
2 changed files with 6 additions and 1 deletions

View File

@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
## Unreleased
## Fixes
- Fix `navigationOptions` type from `NavigationScreenProp<NavigationRoute>` to `NavigationScreenConfig<Options>`.
## [3.11.0]
## New Features

View File

@@ -244,7 +244,7 @@ declare module 'react-navigation' {
| Options
| ((
navigationOptionsContainer: NavigationScreenConfigProps & {
navigationOptions: NavigationScreenProp<NavigationRoute>;
navigationOptions: NavigationScreenConfig<Options>;
}
) => Options);