Navigation Menu

Skip to content

Commit

Permalink
fix: regression in hidden components reconcilation
Browse files Browse the repository at this point in the history
  • Loading branch information
theKashey committed Jun 15, 2019
1 parent fa781a8 commit 3f8efc4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/reconciler/utils.js
Expand Up @@ -67,10 +67,10 @@ export const areSwappable = (a, b) => {

if (isFunctional(a)) {
const nameA = getComponentDisplayName(a);
if (nameA === 'Component' || !areNamesEqual(nameA, getComponentDisplayName(b))) {
if (!areNamesEqual(nameA, getComponentDisplayName(b))) {
return false;
}
return haveTextSimilarity(String(a), String(b));
return nameA !== 'Component' || haveTextSimilarity(String(a), String(b));
}
return false;
};

0 comments on commit 3f8efc4

Please sign in to comment.