dillon1000/react

Commit

Make host context use null as empty and only error in dev (#25609)

Makes it slightly more blazing.

No host config actually uses null as any useful and we use this as a
placeholder value anyway. It's also better for perf since it doesn't let
two different hidden classes pass around. It's also a magic place holder
that triggers error if we do try to access anything from it.
Browse files
Changed paths3 files
First-parent comparison
M packages/react-reconciler/src/ReactFiberHostContext.new.js ModifiedM packages/react-reconciler/src/ReactFiberHostContext.old.js ModifiedM packages/react-reconciler/src/__tests__/ReactFiberHostContext-test.internal.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…