React Hooks

What are React Hooks?

React Hooks are a new feature in React 16.8. They let us access the core features of React such as state without writing Class Components.

Some commons Hooks are:


  • React Hooks start with keyword use
  • The component where we invoke Hooks must be named uppercase
  • We can only use Hooks inside a React Functional component, not a Class Component
  • Only call Hooks at the top level. Don’t call them inside loops, conditions or nested functions