4 ms·
> If you're doing manual VDOM building you're doing something very wrong. Rendering a React or Vue component is building a VDOM, that's what I'm referring to.
by samwillis 3y ago
> If you're doing manual VDOM building you're doing something very wrong.
Rendering a React or Vue component is building a VDOM, that's what I'm referring to. Your code is explicitly building a VDOM.
> The reconciliation makes sure only the parts are re-rendered which have changed.
Yes, and that makes development easier.
That reconciliation is only "faster" if your alternative non-VDOM code is poorly written, throwing away chunks of DOM and rebuilding from scratch.
I'm not advocating for not using VDOM frameworks, I use them, I'm advocating for understanding they are not faster than the DOM. that is a myth, and results in people misunderstanding the tools or how the DOM and browsers work.
- ricardobayes 3y agoYeah I definitely agree with VDOM doesn't necessarily speed up anything on its own. There are many frameworks that benchmark better than react, for example - svelte, lit - these don't have VDOM at all.