full upgrade

This commit is contained in:
2026-01-10 00:52:08 +01:00
parent b487f4ba75
commit ae37294b06
14 changed files with 2680 additions and 1340 deletions

View File

@@ -29,9 +29,14 @@ const nextConfig: NextConfig = {
},
// Performance optimizations
experimental: {
optimizePackageImports: ["lucide-react", "framer-motion"],
},
// NOTE: `optimizePackageImports` can cause dev-time webpack runtime issues with some setups.
// Keep it enabled for production builds only.
experimental:
process.env.NODE_ENV === "production"
? {
optimizePackageImports: ["lucide-react", "framer-motion"],
}
: {},
// Image optimization
images: {
@@ -54,7 +59,7 @@ const nextConfig: NextConfig = {
},
// Webpack configuration
webpack: (config, { isServer, dev, webpack }) => {
webpack: (config) => {
// Fix for module resolution issues
config.resolve.fallback = {
...config.resolve.fallback,
@@ -63,24 +68,6 @@ const nextConfig: NextConfig = {
tls: false,
};
// Safari + React 19 + Next.js 15 compatibility fixes
if (dev && !isServer) {
// Disable module concatenation to prevent factory initialization issues
config.optimization = {
...config.optimization,
concatenateModules: false,
providedExports: false,
usedExports: false,
};
// Add DefinePlugin to ensure proper environment detection
config.plugins.push(
new webpack.DefinePlugin({
"process.env.__NEXT_DISABLE_REACT_STRICT_MODE": JSON.stringify(false),
}),
);
}
return config;
},