Install bundle analyzer

This commit is contained in:
Aarni Halinen
2021-01-15 22:57:07 +02:00
parent 6bcfaa09d0
commit 311bbf0b3f
3 changed files with 162 additions and 3 deletions
+6 -2
View File
@@ -1,6 +1,10 @@
const FaviconsWebpackPlugin = require("favicons-webpack-plugin");
module.exports = {
const withBundleAnalyzer = require('@next/bundle-analyzer')({
enabled: process.env.ANALYZE === 'true',
});
module.exports = withBundleAnalyzer({
target: "server",
webpack: (config) => {
config.plugins.push(
@@ -13,4 +17,4 @@ module.exports = {
);
return config;
}
}
});