mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
add flowtype to function signature (#13285)
This commit is contained in:
committed by
Nathan Hunzaker
parent
261da3f0a9
commit
5cff212072
+35
-7
@@ -146,7 +146,11 @@ export function reconcileChildren(
|
||||
}
|
||||
}
|
||||
|
||||
function updateForwardRef(current, workInProgress, renderExpirationTime) {
|
||||
function updateForwardRef(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
const render = workInProgress.type.render;
|
||||
const nextProps = workInProgress.pendingProps;
|
||||
const ref = workInProgress.ref;
|
||||
@@ -184,7 +188,11 @@ function updateForwardRef(current, workInProgress, renderExpirationTime) {
|
||||
return workInProgress.child;
|
||||
}
|
||||
|
||||
function updateFragment(current, workInProgress, renderExpirationTime) {
|
||||
function updateFragment(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
const nextChildren = workInProgress.pendingProps;
|
||||
reconcileChildren(
|
||||
current,
|
||||
@@ -196,7 +204,11 @@ function updateFragment(current, workInProgress, renderExpirationTime) {
|
||||
return workInProgress.child;
|
||||
}
|
||||
|
||||
function updateMode(current, workInProgress, renderExpirationTime) {
|
||||
function updateMode(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
const nextChildren = workInProgress.pendingProps.children;
|
||||
reconcileChildren(
|
||||
current,
|
||||
@@ -208,7 +220,11 @@ function updateMode(current, workInProgress, renderExpirationTime) {
|
||||
return workInProgress.child;
|
||||
}
|
||||
|
||||
function updateProfiler(current, workInProgress, renderExpirationTime) {
|
||||
function updateProfiler(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
if (enableProfilerTimer) {
|
||||
workInProgress.effectTag |= Update;
|
||||
}
|
||||
@@ -768,7 +784,11 @@ function updatePlaceholderComponent(
|
||||
}
|
||||
}
|
||||
|
||||
function updatePortalComponent(current, workInProgress, renderExpirationTime) {
|
||||
function updatePortalComponent(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
pushHostContainer(workInProgress, workInProgress.stateNode.containerInfo);
|
||||
const nextChildren = workInProgress.pendingProps;
|
||||
if (current === null) {
|
||||
@@ -796,7 +816,11 @@ function updatePortalComponent(current, workInProgress, renderExpirationTime) {
|
||||
return workInProgress.child;
|
||||
}
|
||||
|
||||
function updateContextProvider(current, workInProgress, renderExpirationTime) {
|
||||
function updateContextProvider(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
const providerType: ReactProviderType<any> = workInProgress.type;
|
||||
const context: ReactContext<any> = providerType._context;
|
||||
|
||||
@@ -859,7 +883,11 @@ function updateContextProvider(current, workInProgress, renderExpirationTime) {
|
||||
return workInProgress.child;
|
||||
}
|
||||
|
||||
function updateContextConsumer(current, workInProgress, renderExpirationTime) {
|
||||
function updateContextConsumer(
|
||||
current: Fiber | null,
|
||||
workInProgress: Fiber,
|
||||
renderExpirationTime: ExpirationTime,
|
||||
) {
|
||||
const context: ReactContext<any> = workInProgress.type;
|
||||
const newProps = workInProgress.pendingProps;
|
||||
const render = newProps.children;
|
||||
|
||||
Reference in New Issue
Block a user