How do you optimize a web page for performance and improve core web vitals?
Talk about minimizing bundle sizes (code splitting), image compression, deferring JavaScript, server-side rendering, and caching.
"To optimize frontend performance and boost Core Web Vitals like LCP and FID, I prioritize code-splitting using Next.js dynamic imports to reduce the initial JS bundle size. I compress images using webp format, implement lazy loading for images below the fold, and leverage browser caching. Additionally, I minimize render-blocking resources by deferring non-critical scripts."