Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

327
Views
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 answers
Answer question

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 Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!