How to render the HTML after a stateVariable set in React with TypeScript
Advertisements I’m trying to render a HTML block after a state variable succesfully setted. For this purpose, in below, I defined my state variables and my functions to set them a value. const formService:FormService=new FormService(); const [appointmentDate, setAppointmentDate] = useState<AppointmentDate>(); const [formattedDate, setFormattedDate ]=useState<string>() const [formattedTime, setFormattedTime ]=useState<string>() const [formattedTime20MinutesBefore, setFormattedTime20MinutesBefore] = useState<string>() useEffect(()=>{ init();… Read More How to render the HTML after a stateVariable set in React with TypeScript