React isValidElement

React.isValidElement verifies the object is a React element.

what is a React Element?

React Element is an object representation of a DOM node and contains information about the type, the props and the child of a component.

The next question might be, what is a React Element. React Element is an object representation of a DOM node. The type can be a string, a function or a class.

In conclusion, a React Element is a DOM representation in Virtual DOM and it's valid when has the following:

  • type
  • props
  • child

Back to API