Skip to content

Commit 5cff212

Browse files
ryota-murakaminhunzaker
authored andcommitted
add flowtype to function signature (#13285)
1 parent 261da3f commit 5cff212

File tree

1 file changed

+35
-7
lines changed

1 file changed

+35
-7
lines changed

packages/react-reconciler/src/ReactFiberBeginWork.js

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,11 @@ export function reconcileChildren(
146146
}
147147
}
148148

149-
function updateForwardRef(current, workInProgress, renderExpirationTime) {
149+
function updateForwardRef(
150+
current: Fiber | null,
151+
workInProgress: Fiber,
152+
renderExpirationTime: ExpirationTime,
153+
) {
150154
const render = workInProgress.type.render;
151155
const nextProps = workInProgress.pendingProps;
152156
const ref = workInProgress.ref;
@@ -184,7 +188,11 @@ function updateForwardRef(current, workInProgress, renderExpirationTime) {
184188
return workInProgress.child;
185189
}
186190

187-
function updateFragment(current, workInProgress, renderExpirationTime) {
191+
function updateFragment(
192+
current: Fiber | null,
193+
workInProgress: Fiber,
194+
renderExpirationTime: ExpirationTime,
195+
) {
188196
const nextChildren = workInProgress.pendingProps;
189197
reconcileChildren(
190198
current,
@@ -196,7 +204,11 @@ function updateFragment(current, workInProgress, renderExpirationTime) {
196204
return workInProgress.child;
197205
}
198206

199-
function updateMode(current, workInProgress, renderExpirationTime) {
207+
function updateMode(
208+
current: Fiber | null,
209+
workInProgress: Fiber,
210+
renderExpirationTime: ExpirationTime,
211+
) {
200212
const nextChildren = workInProgress.pendingProps.children;
201213
reconcileChildren(
202214
current,
@@ -208,7 +220,11 @@ function updateMode(current, workInProgress, renderExpirationTime) {
208220
return workInProgress.child;
209221
}
210222

211-
function updateProfiler(current, workInProgress, renderExpirationTime) {
223+
function updateProfiler(
224+
current: Fiber | null,
225+
workInProgress: Fiber,
226+
renderExpirationTime: ExpirationTime,
227+
) {
212228
if (enableProfilerTimer) {
213229
workInProgress.effectTag |= Update;
214230
}
@@ -768,7 +784,11 @@ function updatePlaceholderComponent(
768784
}
769785
}
770786

771-
function updatePortalComponent(current, workInProgress, renderExpirationTime) {
787+
function updatePortalComponent(
788+
current: Fiber | null,
789+
workInProgress: Fiber,
790+
renderExpirationTime: ExpirationTime,
791+
) {
772792
pushHostContainer(workInProgress, workInProgress.stateNode.containerInfo);
773793
const nextChildren = workInProgress.pendingProps;
774794
if (current === null) {
@@ -796,7 +816,11 @@ function updatePortalComponent(current, workInProgress, renderExpirationTime) {
796816
return workInProgress.child;
797817
}
798818

799-
function updateContextProvider(current, workInProgress, renderExpirationTime) {
819+
function updateContextProvider(
820+
current: Fiber | null,
821+
workInProgress: Fiber,
822+
renderExpirationTime: ExpirationTime,
823+
) {
800824
const providerType: ReactProviderType<any> = workInProgress.type;
801825
const context: ReactContext<any> = providerType._context;
802826

@@ -859,7 +883,11 @@ function updateContextProvider(current, workInProgress, renderExpirationTime) {
859883
return workInProgress.child;
860884
}
861885

862-
function updateContextConsumer(current, workInProgress, renderExpirationTime) {
886+
function updateContextConsumer(
887+
current: Fiber | null,
888+
workInProgress: Fiber,
889+
renderExpirationTime: ExpirationTime,
890+
) {
863891
const context: ReactContext<any> = workInProgress.type;
864892
const newProps = workInProgress.pendingProps;
865893
const render = newProps.children;

0 commit comments

Comments
 (0)