root container

The existing page element, often <div id="root">, into which React renders an application.

In more detail

You pass it to createRoot, and React manages everything inside it. React also attaches its delegated event listeners to this element, so separate React roots on one page stay independent.

Related terms

Taught in

References