Raja Muhammad Asher
Raja Muhammad Asher

Raja Muhammad Asher

What is the virtual DOM? How does react use the
virtual DOM to render the UI?

Photo by Lautaro Andreani on Unsplash

What is the virtual DOM? How does react use the virtual DOM to render the UI?

Raja Muhammad Asher's photo
Raja Muhammad Asher
·Aug 25, 2022·

1 min read

The virtual DOM (VDOM) is a programming concept where an ideal, or “virtual”, representation of a UI is kept in memory and synced with the “real” DOM by a library such as ReactDOM. This process is called reconciliation. During reconciliation, React calculates what exactly has changed without involving the actual DOM and then ensures that the actual DOM only repaints the necessary data.

Sources:

Virtual DOM and Internals –. (n.d.). React. reactjs.org/docs/faq-internals.html

 
Share this