mirror of
https://github.com/status-im/react-native.git
synced 2025-02-25 07:35:25 +00:00
React sync for revisions 9491dee...a7b9f98
Reviewed By: sebmarkbage Differential Revision: D6834573 fbshipit-source-id: 30829313053ecec54a891941fcf090021497ef8e
This commit is contained in:
parent
afd988f85a
commit
d676746f14
@ -1 +1 @@
|
||||
9491dee79586d21c115cd4d5986c81b7d88d2b3f
|
||||
a7b9f98e7abab7305978b4b36881c8267a450097
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -9,8 +9,12 @@
|
||||
|
||||
'use strict';
|
||||
|
||||
var ReactFeatureFlags = {
|
||||
const ReactFeatureFlags = {
|
||||
debugRenderPhaseSideEffects: false,
|
||||
// TODO (T25573762) Hook this up to a GK for Facaebook engineers (DEV + prod).
|
||||
debugRenderPhaseSideEffectsForStrictMode: true,
|
||||
// TODO (T25573607) Enable this warning once deprecation codemod has been run.
|
||||
warnAboutDeprecatedLifecycles: false,
|
||||
};
|
||||
|
||||
module.exports = ReactFeatureFlags;
|
||||
|
@ -10,11 +10,13 @@
|
||||
|
||||
export type ReactNode =
|
||||
| React$Element<any>
|
||||
| ReactCall
|
||||
| ReactReturn
|
||||
| ReactCall<any>
|
||||
| ReactReturn<any>
|
||||
| ReactPortal
|
||||
| ReactText
|
||||
| ReactFragment;
|
||||
| ReactFragment
|
||||
| ReactProvider<any>
|
||||
| ReactConsumer<any>;
|
||||
|
||||
export type ReactFragment = ReactEmpty | Iterable<React$Node>;
|
||||
|
||||
@ -24,18 +26,71 @@ export type ReactText = string | number;
|
||||
|
||||
export type ReactEmpty = null | void | boolean;
|
||||
|
||||
export type ReactCall = {
|
||||
export type ReactCall<V> = {
|
||||
$$typeof: Symbol | number,
|
||||
type: Symbol | number,
|
||||
key: null | string,
|
||||
children: any,
|
||||
// This should be a more specific CallHandler
|
||||
handler: (props: any, returns: Array<mixed>) => ReactNodeList,
|
||||
ref: null,
|
||||
props: {
|
||||
props: any,
|
||||
// This should be a more specific CallHandler
|
||||
handler: (props: any, returns: Array<V>) => ReactNodeList,
|
||||
children?: ReactNodeList,
|
||||
},
|
||||
};
|
||||
|
||||
export type ReactReturn = {
|
||||
export type ReactReturn<V> = {
|
||||
$$typeof: Symbol | number,
|
||||
value: mixed,
|
||||
type: Symbol | number,
|
||||
key: null,
|
||||
ref: null,
|
||||
props: {
|
||||
value: V,
|
||||
},
|
||||
};
|
||||
|
||||
export type ReactProvider<T> = {
|
||||
$$typeof: Symbol | number,
|
||||
type: ReactProviderType<T>,
|
||||
key: null | string,
|
||||
ref: null,
|
||||
props: {
|
||||
value: T,
|
||||
children?: ReactNodeList,
|
||||
},
|
||||
};
|
||||
|
||||
export type ReactProviderType<T> = {
|
||||
$$typeof: Symbol | number,
|
||||
context: ReactContext<T>,
|
||||
};
|
||||
|
||||
export type ReactConsumer<T> = {
|
||||
$$typeof: Symbol | number,
|
||||
type: ReactContext<T>,
|
||||
key: null | string,
|
||||
ref: null,
|
||||
props: {
|
||||
render: (value: T) => ReactNodeList,
|
||||
bits?: number,
|
||||
},
|
||||
};
|
||||
|
||||
export type ReactContext<T> = {
|
||||
$$typeof: Symbol | number,
|
||||
provide(value: T, children: ReactNodeList, key?: string): ReactProvider<T>,
|
||||
consume(
|
||||
render: (value: T) => ReactNodeList,
|
||||
observedBits?: number,
|
||||
key?: string,
|
||||
): ReactConsumer<T>,
|
||||
calculateChangedBits: ((a: T, b: T) => number) | null,
|
||||
defaultValue: T,
|
||||
currentValue: T,
|
||||
changedBits: number,
|
||||
|
||||
// DEV only
|
||||
_currentRenderer?: Object | null,
|
||||
};
|
||||
|
||||
export type ReactPortal = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user