No entiendo como debo inicializar el estado del componente StateFulComponent
Tu código hasta el momento
class StatefulComponent extends React.Component {
constructor(props) {
super(props);
// Only change code below this line
this.state = {
name : "FirstName"
}
// Only change code above this line
}
render() {
return (
<div>
<h1>{this.state.firstName}</h1>
</div>
);
}
};
Información de tu navegador:
El agente de usuario es: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36
Desafío: React js - Crea un componente de estado
Enlaza al desafío: