text: if (!localStorage.user) {
    location.replace("./login.html");
  }
  
  window.addEventListener("load", function () {
    const userName = document.querySelector(".user-info p");
    const btnCerrar = document.querySelector("#closeApp");
    const deposito = JSON.parse(localStorage.getItem("user"));
  
    //renderizamos el nombre de usuario
    userName.innerText = deposito.name;
    btnCerrar.addEventListener("click", function () {
      //limpio el localStorage
      localStorage.clear();
      //envío al usuario a loogearse
      location.replace("./login.html");
    });
  });
  