mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-22 11:57:33 +08:00
Change type to accept ComponentType
Change type to accept React.ComponentType to accomodate for stateless as well as standard components
This commit is contained in:
4
types/react-native/index.d.ts
vendored
4
types/react-native/index.d.ts
vendored
@@ -440,7 +440,7 @@ export interface Touchable {
|
||||
onTouchEndCapture?: (event: GestureResponderEvent) => void
|
||||
}
|
||||
|
||||
export type ComponentProvider = () => React.ComponentClass<any>
|
||||
export type ComponentProvider = () => React.ComponentType<any>
|
||||
|
||||
export type AppConfig = {
|
||||
appKey: string;
|
||||
@@ -4574,7 +4574,7 @@ export interface SceneConfigs {
|
||||
}
|
||||
|
||||
export interface Route {
|
||||
component?: React.ComponentClass<ViewProperties>
|
||||
component?: React.ComponentType<any>
|
||||
id?: string
|
||||
title?: string
|
||||
passProps?: Object;
|
||||
|
||||
Reference in New Issue
Block a user