diff --git a/types/react-native/index.d.ts b/types/react-native/index.d.ts index ae3127bc1d..2c8575b211 100644 --- a/types/react-native/index.d.ts +++ b/types/react-native/index.d.ts @@ -912,6 +912,11 @@ export interface TextProps extends TextPropsIOS, TextPropsAndroid, Accessibility * Used to locate this view in end-to-end tests. */ testID?: string; + + /** + * Used to reference react managed views from native code. + */ + nativeID?: string; } /** @@ -2031,6 +2036,11 @@ export interface ViewProps * Used to locate this view in end-to-end tests. */ testID?: string; + + /** + * Used to reference react managed views from native code. + */ + nativeID?: string; } /** diff --git a/types/react-native/test/index.tsx b/types/react-native/test/index.tsx index 79c5a111ca..f3dfb45b51 100644 --- a/types/react-native/test/index.tsx +++ b/types/react-native/test/index.tsx @@ -832,3 +832,12 @@ const SwitchColorTest = () => ( const SwitchThumbColorTest = () => ( ) + +const NativeIDTest = () => ( + + + + Text + + +)