Files
frontend/next.config.ts
T
Thanh Quy - wolf 37a6ed58c9 Connect backend
2026-04-19 17:04:07 +07:00

35 lines
844 B
TypeScript

import type { NextConfig } from "next";
/**
* Next.js configuration.
*
* Currently uses all defaults — no custom rewrites, redirects, or image domains needed.
* Add options here as the project grows (e.g. `images.remotePatterns` when using
* external image URLs, `experimental.serverActions` for form handling, etc.)
*
* Docs: https://nextjs.org/docs/app/api-reference/next-config-js
*/
const nextConfig: NextConfig = {
output: "standalone",
images: {
remotePatterns: [
{
protocol: "https",
hostname: "images.unsplash.com",
},
],
},
async rewrites() {
const gateway =
process.env.GATEWAY_INTERNAL_URL ?? "http://localhost:3000";
return [
{
source: "/api/:path*",
destination: `${gateway}/api/:path*`,
},
];
},
};
export default nextConfig;