Skip to content

Commit 920be19

Browse files
committed
Children of a Timeout must be strict mode compatible
Async is not required for Suspense, but strict mode is.
1 parent d378055 commit 920be19

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

packages/react-reconciler/src/ReactFiber.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -353,6 +353,9 @@ export function createFiberFromElement(
353353
break;
354354
case REACT_TIMEOUT_TYPE:
355355
fiberTag = TimeoutComponent;
356+
// Suspense does not require async, but its children should be strict
357+
// mode compatible.
358+
mode |= StrictMode;
356359
break;
357360
default: {
358361
if (typeof type === 'object' && type !== null) {

0 commit comments

Comments
 (0)