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

326
Visualizações
how to read and remove too many unused js code in chunk

enter image description here

My nextjs project calls the main page, and 98% of unused bytes exist in one chunk of chunks.

When I looked into the code, there was a red line marked on this type of code.

"use strict";
eval(...)

I'm not sure what that means. Does it mean that the unused code was imported and used?

I need your help and a keyword to find a clue.

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

0

you're running your tests in a development environment. that's why you're shipping so much unused JS. to fix this run next build to generate an optimized bundle.

in production, if you want to figure out why a package was imported I suggest using bundle-analyzer.

as for what they are.

  • The eval() function evaluates JavaScript code represented as a string. source
  • "use strict"; Defines that JavaScript code should be executed in "strict mode". source
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