Skip to content

Commit

Permalink
Merge pull request #2888 from Zeral-Zhang/develop
Browse files Browse the repository at this point in the history
fix(react-simulator-renderer): detached node has children
  • Loading branch information
1ncounter authored Jan 26, 2024
2 parents 6e89d4d + b29c539 commit dfe6878
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/react-simulator-renderer/src/renderer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ function getNodeInstance(fiberNode: any, specId?: string): IPublicTypeNodeInstan

function checkInstanceMounted(instance: any): boolean {
if (isElement(instance)) {
return instance.parentElement != null;
return instance.parentElement != null && window.document.contains(instance);
}
return true;
}
Expand Down

0 comments on commit dfe6878

Please sign in to comment.