feat(web): add simple auth UI + enable CORS for testing

这个提交包含在:
anygen-build-bot
2026-02-12 10:02:13 +00:00
父节点 4930a02232
当前提交 15211a99de
修改 5 个文件,包含 189 行新增58 行删除

查看文件

@@ -1,7 +1,21 @@
import type { NextConfig } from "next";
const nextConfig: NextConfig = {
/* config options here */
// For local dev convenience. In production you should configure reverse proxy
// and set NEXT_PUBLIC_API_BASE to your public API origin.
async rewrites() {
// If the user sets NEXT_PUBLIC_API_BASE to "/api", we can proxy to backend
// from the Next.js server (SSR). This does NOT affect browser fetch.
const backendInternal = process.env.BACKEND_INTERNAL_URL;
if (!backendInternal) return [];
return [
{
source: "/api/:path*",
destination: `${backendInternal}/api/:path*`,
},
];
},
};
export default nextConfig;