Explaining useEffect Hook in React

Index

What is useEffect Hook?

import React, { useState } from "react";const Practise = () => {const [count, setCount] = useState(0);return (<><div><p>You clicked {count} times</p><button onClick={() => setCount(count + 1)}>Click me</button></div>);</>);};export default Practise;

--

--

--

I am a front-end developer from India with over one year of experience in freelancing with skills like Git, HTML5, CSS3, Bootstrap 4&5, and React.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

How to Setup Real-Time Data Flow with Action Cable, Rails and React JS

Create your 1st React App

Accessing the Previous URL in Angular

React/Redux project Final Thoughts - Software Engineering Program of Flatiron School

Using a custom domain with GitHub Pages

React JS Bad Practices

🤙Join us in ONE HOUR for the @bprotocoleth Community Call on Discord!

NodeJS for the Web Pi Kiosk

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Ateev Duggal

Ateev Duggal

I am a front-end developer from India with over one year of experience in freelancing with skills like Git, HTML5, CSS3, Bootstrap 4&5, and React.

More from Medium

Moving components using react.

React Hooks With Context

React Hooks & ‘customHook(s)’

React: useEffect and componentDidMount