Understand Virtual DOM in React and What Makes It Great

Understand Virtual DOM in React and What Makes It Great
4 min read
16 February 2023

What is a virtual DOM?

How does Virtual DOM actually work?

<div>
<div>
<h1>Hello World</h1>
</div>
<div>
<h1>Hello Universe</h1>
</div>
</div>
<div>
<div>
<h1>Hello World</h1>
</div>
<div>
<h1>Hello Planet</h1>
</div>
</div>
Understand Virtual DOM in React and What Makes It Great

The Functional aspects of Virtual DOM

  1. Speed and performance boost
  2. Lightweight
  3. It is simple and clear
  4. Amazing diffing algorithm
  5. It can be used on other frameworks not just react
  1. Higher memory usage problems as the diffing algorithms need to keep comparing the elements to know which components needs to be updated or changed.
  2. It is not easily integrated into many other frameworks.
  3. You can’t use it or target template engines.

Even at the cons mentioned above, virtual DOM is always the go-to because of the boost in performance and speed it offers.

What can we conclude?

In case you have found a mistake in the text, please send a message to the author by selecting the mistake and pressing Ctrl-Enter.
Aditya Jani 334
Aditya is dedicated to revolutionizing businesses by incorporating fresh concepts into their digital endeavors. Currently, he is employed at Ace Infoway and has...
Comments (0)

    No comments yet

You must be logged in to comment.

Sign In / Sign Up

  • React DOM/Virtual DOM

    There are hundreds of articles floating which deal with the comparison of DOM and React-DOM.But what is React-DOM or what is DOM for that matter.Let’s unw...

    Rajasree Pothula · 17 July 2023 · 22