Day 50: React Course on Udemy

Rendering More Than One Element
React will only output one element. When you're trying to render more than one element to the DOM, an important thing to remember is to wrap adjacent JSX elements in an enclosing tag. i.e.

You then render that div, and both elements will be rendered to the DOM.

ReactDOM.render(
  <div>
    <h1>Hello World</h1>
    <p>My name is Himashi</p>
  </div>,
  document.getElementById("app")
);