React JS

React Lifecycle Methods

React lifecycle methods are special methods that allows us to hook into the various stages of a component's lifecycle. These methods provide a way to execute code at specific points during the component's existence. React lifecycle methods basically consist of 3 main...

read more

How Virtual DOM works in React? (step-by-step)

Following are the steps in which Virtual DOM updates and enable re-renders. Initial Render. When we first render a React component, React creates a Virtual DOM representation of the component and its child components. Diffing. Whenever there is a change in the...

read more

useState Hook

The useState hook is used for managing state within functional components. State represents the data that can change over time in a component. Prior to the introduction of hooks in React, functional components were stateless and state management could only be done...

read more