DEV Community

Discussion on: ⚛️ Reparenting is now possible with React

Collapse
 
bduffany profile image
Brandon Duffany • Edited

Nice article!

For readers like me who are looking for a way to reparent an expensive element without re-rendering, note that this solution DOES trigger a re-render, so the actual DOM node is destroyed and re-built. So you may want to look elsewhere. (I'm still looking for a solution myself)

Collapse
 
paolimi profile image
Paolo Longo

The aim of the project is exactly to avoid this. The re-render takes place but the element is not reconstructed thanks to the work that is done at the React internals.