[Beta] Javascript Bundle Analysis

What is Bundle Analysis?

Bundle Analysis helps improve your application's performance, bandwidth usage, and load times by letting you know if what you’re about to merge will cause any performance regressions. It will allow you to explore all of the modules in your bundle and determine where you might be able to streamline your bundle size as well as find areas of concern.

Main Features

  • Asset and Module exploration

    On the Bundles Tab in the Codecov UI you’ll see a simple summary of the size of your bundle: total size, gzip size, and download time to help you understand just how much bundle size may be impacting user experience.

  • Commit and Pull Request bundle breakdown

    To help you dig deeper, we incorporated Bundle Analysis into our Commit and Pull Request pages. This means you can now pinpoint the exact commit and Pull Request responsible for any bundle size changes, allowing for a better understanding of your code changes.

  • Bundle information via PR comment

    See if your bundle size increases or – better yet – decreases in the Codecov PR comment. There’s no need to leave the Pull Request to understand how a code change impacts your bundle size – unless you want to dig deeper, which you definitely should.

Getting started:

To use Bundle Analysis, users can opt for a bundler plugin setup with current support for Rollup, Vite, and Webpack. To get started all you need to do is:

  • Install one of the plugins as a dev dependency
  • Configure it in your bundler config
  • Make a commit
  • Build

Framework specific guides for those frameworks can be found below

Having trouble with Vercel and the Bundle Analysis plugins?

Environment Specific Requirements