From 69075237cf84de8def4682b6df3649c576e06017 Mon Sep 17 00:00:00 2001 From: Ishaan Jaffer Date: Wed, 6 May 2026 18:34:40 -0700 Subject: [PATCH] fix(ui): drop output:export so /agents/[id] dynamic routes work in dev --- ui/litellm-dashboard/next.config.mjs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/ui/litellm-dashboard/next.config.mjs b/ui/litellm-dashboard/next.config.mjs index cfaeb24dc5d..25ec598b0d4 100644 --- a/ui/litellm-dashboard/next.config.mjs +++ b/ui/litellm-dashboard/next.config.mjs @@ -5,10 +5,13 @@ import { fileURLToPath } from "url"; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); +// `output: "export"` is intentionally omitted here. Static export is incompatible +// with `dynamicParams: true` (the App Router default), which broke routes like +// /agents/[agent_id] and /agents/[agent_id]/sessions/[session_id]. The proxy +// production build is produced by `npm run build` separately when needed; in +// dev (`pnpm dev`) and standard server builds, dynamic routes work normally. +// See https://nextjs.org/docs/app/building-your-application/deploying/static-exports const nextConfig = { - output: "export", - // Required with output: "export" — default image optimizer runs only in server mode. - // See https://nextjs.org/docs/messages/export-image-api images: { unoptimized: true, },