douyinWEB/frontend/next.config.mjs
2026-08-10 20:11:23 -05:00

20 lines
410 B
JavaScript

/** @type {import('next').NextConfig} */
const apiBase = process.env.DY_INTERNAL_API_URL || "http://127.0.0.1:8014";
const nextConfig = {
async rewrites() {
return [
{
source: "/api/:path*",
destination: `${apiBase}/api/:path*`,
},
{
source: "/covers/:path*",
destination: `${apiBase}/covers/:path*`,
},
];
},
};
export default nextConfig;