Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

139
Visualizações
How does google chrome save my authenticated user even after I refresh the page?

So I am making a firebase web app and I am authenticating the user at the moment. When the user signs in, it takes them to a brand new page and refreshes the page. I was told that when you refresh the page all the memory is cleared.

What I don't understand is somehow chrome saves the user even after I refresh the page. So the current user stays logged in even though the memory should have been cleared.

How does chrome do this? Shouldn't I have to log my user into firebase again after the user refreshes the page? It just doesn't make sense how the user is still logged in even though the page is refreshed and the memory was cleared. I would just like more information on what exactly is going on.

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

When the user signs in, the Firebase Authentication SDK stores the (encoded) user credentials in the local storage of the user's browser.

When you (re)load the page, the SDK restores the user's authentication state from that information in local storage.

This does require it to call to the server though (a.o. to check if the account was disabled in the meantime), so to pick up when the credentials have been restored use an auth state listener.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda