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

350
Visualizações
Using Service Worker in Angular leading to 504 Error

I tried to implement Service Workers on an Angular Project lately, it seems to be caching all the files accordingly, the problem is, we kinda get a weird behaviour for going offline. When going Offline, the site can be used as normal and everything works fine, when trying to refresh the site, we get an 504 Error. On the other hand, if we check the "update on reload" checkbox on chrome (which should only create a new instance for the service worker AFAIK), reload the site online, and then uncheck the "update on reload" and go offline again, i can refresh as often as i like, everything works just fine. We also tried to implement a logic to have the service worker update everytime the site is refreshed, but this doesn't seem to be working either.

Does anyone know what is causing this weird behaviour? I mean it seems to be working just fine, but just under certain circumstances.

504 Error that comes when going offline

Everything is coming from the service worker after checking "update on reload" and going offline

about 4 years ago · Juan Pablo Isaza
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