mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Replace React.AbstractComponent with component type in View (#46916)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/46916 Prepare for the ref-as-prop typing change in flow. Changelog: [Internal] Reviewed By: SamChou19815 Differential Revision: D64104990 fbshipit-source-id: c747f4e89b5631a6c1543aca86cbea4db4987f5a
This commit is contained in:
committed by
Facebook GitHub Bot
parent
ab8f3ff3e9
commit
f86a14e4ad
+4
-4
@@ -23,10 +23,10 @@ export type Props = ViewProps;
|
||||
*
|
||||
* @see https://reactnative.dev/docs/view
|
||||
*/
|
||||
const View: React.AbstractComponent<
|
||||
ViewProps,
|
||||
React.ElementRef<typeof ViewNativeComponent>,
|
||||
> = React.forwardRef(
|
||||
const View: component(
|
||||
ref: React.RefSetter<React.ElementRef<typeof ViewNativeComponent>>,
|
||||
...props: ViewProps
|
||||
) = React.forwardRef(
|
||||
(
|
||||
{
|
||||
accessibilityElementsHidden,
|
||||
|
||||
@@ -3924,10 +3924,10 @@ declare module.exports: ReactNativeViewAttributes;
|
||||
|
||||
exports[`public API should not change unintentionally Libraries/Components/View/View.js 1`] = `
|
||||
"export type Props = ViewProps;
|
||||
declare const View: React.AbstractComponent<
|
||||
ViewProps,
|
||||
React.ElementRef<typeof ViewNativeComponent>,
|
||||
>;
|
||||
declare const View: component(
|
||||
ref: React.RefSetter<React.ElementRef<typeof ViewNativeComponent>>,
|
||||
...props: ViewProps
|
||||
);
|
||||
declare module.exports: View;
|
||||
"
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user