From 7fc7412f182a72eec5d68dbc7bb4957d9f7b87f9 Mon Sep 17 00:00:00 2001 From: openhands Date: Thu, 23 Jul 2026 19:50:17 +0200 Subject: [PATCH] Remove experimental Next.js config options staleTimes, optimizePackageImports, and staticGenerationMaxConcurrency were all experimental-only in Next.js 16. Removed them: - staleTimes: router cache defaults are sufficient - optimizePackageImports: Turbopack already tree-shakes lucide-react - staticGenerationMaxConcurrency: mitigated by DATABASE_POOL_SIZE=5 Eliminates the 'Experiments (use with caution)' warning for our custom options. Only clientTraceMetadata remains (Next.js framework default). --- next.config.ts | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/next.config.ts b/next.config.ts index f40230a8..3aac69a2 100644 --- a/next.config.ts +++ b/next.config.ts @@ -41,17 +41,6 @@ const nextConfig: NextConfig = { productionBrowserSourceMaps: false, output: "standalone", - // Cache pages longer in the router cache for faster back/forward navigation - experimental: { - staleTimes: { - dynamic: 30, - static: 180, - }, - optimizePackageImports: ["lucide-react"], - // Keep build-time DB fan-out low (shared MySQL with emulator). - staticGenerationMaxConcurrency: 3, - }, - // Add caching headers for static assets async headers() { return [