Skip to content

Commit

Permalink
[devtools] Fix can't expand in some scenario
Browse files Browse the repository at this point in the history
  • Loading branch information
iChenLei committed Jan 3, 2021
1 parent 50393dc commit a8111b2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/react-devtools-shared/src/hydration.js
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,9 @@ export function hydrate(

const value = parent[last];

if (value.type === 'infinity') {
if (!value) {
return;
} else if (value.type === 'infinity') {
parent[last] = Infinity;
} else if (value.type === 'nan') {
parent[last] = NaN;
Expand Down

0 comments on commit a8111b2

Please sign in to comment.