Context API is a react feature used to share data between multiple components without using props methods.
By using props method here comes the issue named props drilling ,shows that the same data have pass through each component, if some components doesn't need that data but also have access of it.
So to avoid this we using context
How Context API works
Context API mainly involves three things:
- createContext() – Creates a context.
- Provider – Makes data available to child components.
- useContext() – Allows components to access that data.


