Skip to content

Commit

Permalink
Back out "React Native sync for revisions fccf3a9...47cf4e5"
Browse files Browse the repository at this point in the history
Summary:
There's some problem in the last sync that changes the memoization behavior in some product code. We'll revert and investigate.

Changelog: [internal]

Reviewed By: bvanderhoof

Differential Revision: D44100907

fbshipit-source-id: 233b478dd6f2f29121ac05323047ab6099b6b56c
  • Loading branch information
rubennorte authored and facebook-github-bot committed Mar 15, 2023
1 parent 01e7ff5 commit 06b97ca
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 27 deletions.
2 changes: 1 addition & 1 deletion Libraries/Renderer/REVISION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
47cf4e578c2d8eef9c6cc27105ce560307999244
fccf3a9fba5fd778c678657c556344b333111cfb
41 changes: 15 additions & 26 deletions Libraries/Renderer/shims/ReactNativeTypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
*
* @noformat
* @flow strict
* @generated SignedSource<<4df0c7d45c633ce1409906d78ee6813c>>
* @generated SignedSource<<265b342f0d29323bebb711ba0bc882ec>>
*
* This file was sync'd from the facebook/react repository.
*/
Expand Down Expand Up @@ -98,23 +98,7 @@ export type PartialViewConfig = $ReadOnly<{
validAttributes?: PartialAttributeConfiguration,
}>;

/**
* Current usages should migrate to this definition
*/
export interface INativeMethods {
blur(): void;
focus(): void;
measure(callback: MeasureOnSuccessCallback): void;
measureInWindow(callback: MeasureInWindowOnSuccessCallback): void;
measureLayout(
relativeToNativeNode: number | ElementRef<HostComponent<mixed>>,
onSuccess: MeasureLayoutOnSuccessCallback,
onFail?: () => void,
): void;
setNativeProps(nativeProps: {...}): void;
}

export type NativeMethods = $ReadOnly<{|
export type NativeMethods = $ReadOnly<{
blur(): void,
focus(): void,
measure(callback: MeasureOnSuccessCallback): void,
Expand All @@ -125,11 +109,7 @@ export type NativeMethods = $ReadOnly<{|
onFail?: () => void,
): void,
setNativeProps(nativeProps: {...}): void,
|}>;

// This validates that INativeMethods and NativeMethods stay in sync using Flow!
declare var ensureNativeMethodsAreSynced: NativeMethods;
(ensureNativeMethodsAreSynced: INativeMethods);
}>;

export type HostComponent<T> = AbstractComponent<T, $ReadOnly<NativeMethods>>;

Expand Down Expand Up @@ -215,8 +195,6 @@ export type ReactNativeType = {
...
};

export opaque type Node = mixed;

export type ReactFabricType = {
findHostInstance_DEPRECATED<TElementType: ElementType>(
componentOrHandle: ?(ElementRef<TElementType> | number),
Expand All @@ -240,7 +218,18 @@ export type ReactFabricType = {
concurrentRoot: ?boolean,
): ?ElementRef<ElementType>,
unmountComponentAtNode(containerTag: number): void,
getNodeFromInternalInstanceHandle(internalInstanceHandle: mixed): ?Node,
...
};

export type ReactNativeEventTarget = {
node: {...},
canonical: {
_nativeTag: number,
viewConfig: ViewConfig,
currentProps: {...},
_internalInstanceHandle: {...},
...
},
...
};

Expand Down

0 comments on commit 06b97ca

Please sign in to comment.