Next.js provides built-in support for many core-js methods by default.Running 'next build' generates an optimized version of your application for production.The project plans to switch from using Babel to SWC as the compiler for Next.js.There is an existing dependency on core-js and regenerator-runtime that needs evaluation.A step-by-step guide is provided for transitioning from Babel to SWC in Next.js.Solution 1 to remove Babel configuration faced issues due to Enzyme dependency.Solution 2 involves using SWC for production and development, and Babel for testing.Comparisons of bundle size, first load JS, and build time show SWC performing better than Babel.To prevent fallback to using Babel, ensure no Babel configuration files are present in the production environment.Adding console messages in the configuration files can help identify which compiler is being used.