Shyam Sundarshyam3050.hashnode.devยทAug 24, 2023Deep dive into the useState() Hook in React.js.import {useState} from "react"; const Header = () => { const [num, setnum] = useState(1); function updater(){ console.log(num); // 1 (for the first time button click) setnum((prevStateValue) => prevStateValue + 1); console.log(num); // 1 (for the...ReactAdd a thoughtful commentNo comments yetBe the first to start the conversation.