Download next.js/bench/vercel/benchmark-app/next.config.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 901 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/bench/vercel/benchmark-app/next.config.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/bench/vercel/benchmark-app/next.config.js
-
curl -L -o next.config.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/bench/vercel/benchmark-app/next.config.js
901 Bytes
| const { StatsWriterPlugin } = require('webpack-stats-plugin') | |
| const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer') | |
| module.exports = { | |
| experimental: { | |
| appDir: true, | |
| }, | |
| webpack: (config, options) => { | |
| const { nextRuntime = 'client' } = options | |
| if (process.env.ANALYZE) { | |
| if (nextRuntime === 'edge') | |
| config.plugins.push( | |
| new BundleAnalyzerPlugin({ | |
| analyzerMode: 'static', | |
| openAnalyzer: true, | |
| reportFilename: options.isServer | |
| ? '../analyze/server.html' | |
| : './analyze/client.html', | |
| }) | |
| ) | |
| config.plugins.push( | |
| new StatsWriterPlugin({ | |
| filename: `../webpack-stats-${nextRuntime}.json`, | |
| stats: { | |
| assets: true, | |
| chunks: true, | |
| modules: true, | |
| }, | |
| }) | |
| ) | |
| } | |
| return config | |
| }, | |
| } | |