feat: add bundle analyzer for performance monitoring
- Installed @next/bundle-analyzer for bundle size analysis - Configured Next.js to optionally run bundle analysis with ANALYZE=true - Note: Bundle analyzer not yet compatible with Turbopack builds - Manual analysis shows well-optimized bundle: * Largest chunks: 114K (React/core), 110K (store/state) * CSS bundle: 34K * Most chunks under 30K thanks to code splitting * Total static chunks: 864K - Code splitting already implemented for all tools - Lazy loading active for optimal performance 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,9 @@
|
||||
import type { NextConfig } from 'next';
|
||||
import bundleAnalyzer from '@next/bundle-analyzer';
|
||||
|
||||
const withBundleAnalyzer = bundleAnalyzer({
|
||||
enabled: process.env.ANALYZE === 'true',
|
||||
});
|
||||
|
||||
const nextConfig: NextConfig = {
|
||||
output: 'export',
|
||||
@@ -19,4 +24,4 @@ const nextConfig: NextConfig = {
|
||||
},
|
||||
};
|
||||
|
||||
export default nextConfig;
|
||||
export default withBundleAnalyzer(nextConfig);
|
||||
|
||||
Reference in New Issue
Block a user