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

153
Visualizações
JS Lazy loading Server Implementation

If I have an Angular or React Single Page application and some of the routes are lazy loaded, my understanding is that if a user opens the web app, some of the JS bundles won't immediately be sent to their browser. But if they navigate to some of the lazy-loaded routes, then the additional JS bundles will be sent to the browser.

Let's say I'm hosting the app on Firebase hosting, or some other CDN. How can the hosting server possibly implement the logic to know which JS bundles to send to the user? Am I misunderstanding something? I haven't seen much discussion online about this topic, but it doesn't make much sense to me.

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

0

Hosting provider does not know; its not their job.

With code-splitting and dynamic import techniques, you can lazyload parts.

https://reactjs.org/docs/code-splitting.html#reactlazy

https://reactrouter.com/docs/en/v6/examples/lazy-loading

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