Skip to content

Latest commit

 

History

History
21 lines (15 loc) · 664 Bytes

notes.md

File metadata and controls

21 lines (15 loc) · 664 Bytes

React Fragment

  • <React.Fragment> is an empty tag that does not create extra divs inside a component
  • <></> is same as <React.Fragment></React.Fragment>
  • We cannot pass props to React Fragment.
  • It is a component, which is exported by React.

Note

<></> can also be written as <React.Fragment></React.Fragment>.Fragment>

JSX

  • There can be only one parent inside a component.
  • JSX only have one parent

What is a Virtual DOM?

  • It is a representation of DOM.

React reconciliation:

  • React reconciliation is a diff algorithm that React uses to find the differences between the trees to improve the speed of application.