rsnext/examples/with-webpack-bundle-size-analyzer/README.md

24 lines
767 B
Markdown
Raw Normal View History

# Webpack Bundle Size Analyzer
This example shows how to analyze the output bundles using [webpack-bundle-size-analyzer](https://www.npmjs.com/package/webpack-bundle-size-analyzer)
## How to use
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/create/) to bootstrap the example:
```bash
npx create-next-app --example with-webpack-bundle-size-analyzer with-webpack-bundle-size-analyzer-app
# or
yarn create next-app --example with-webpack-bundle-size-analyzer with-webpack-bundle-size-analyzer-app
```
## Notes
To analyze your webpack output, invoke the following command:
```bash
npm run analyze
# or
yarn analyze
```