score:1

Accepted answer
useEffect(() => {
    // This should get called every time status changes
    console.log("Status ------>", status);
}, [status])

score:0

<Nav.Link
    href='#'
    onClick={(e)=> {
            e.preventDefault();
            setStatus('active');
        }
    }
>
    Active
</Nav.Link> 

score:0

const Cardbody: React.FC = (props: any)=>{
    return(
         <div>    
             {props.status}
      </div>     
    );
};
export default Cardbody;

Related Query

More Query from same tag