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

183
Visualizações
How does requestAnimationFrame transform translate optimize for stuff out of browser viewport

I have some code when attached to a wrapper div, creates inserts some divs inside the wrapper div and that runs an animation loop for a second, moving child divs around.

I have a list of divs, on each div I attach this code and move the child divs around.

So if I layout these list of divs on top of each other with no styling they all become visible inside viewport, and there is some lag while moving animation of the child divs.

But if I layout these list of divs in a display flex, and a vertical scrollbar appears, only one item is visible in the viewport, there is no lag, child divs move smoothly.

I was wondering since there is no lag with display flex, as I present, I don't need to worry about only attaching items as they become visible, like as if lazy loading images.

And maybe get to the bottom of this, why is there lag on the first scenario?

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