28 lines
864 B
TypeScript
28 lines
864 B
TypeScript
import type { NextConfig } from "next";
|
|
|
|
const nextConfig: NextConfig = {
|
|
allowedDevOrigins: ["192.168.100.6"],
|
|
output: "standalone",
|
|
// Files in public/ are served with `Cache-Control: public, max-age=0` by
|
|
// default, because Next.js can't know whether they change. kd-tile.png is
|
|
// hot-linked by an external HTML email signature, so its URL is a fixed
|
|
// contract and its bytes never change — pin it to a long-lived immutable
|
|
// cache so mail clients and their image proxies stop re-fetching it.
|
|
// Headers are matched before the filesystem, so this applies to public/.
|
|
async headers() {
|
|
return [
|
|
{
|
|
source: "/kd-tile.png",
|
|
headers: [
|
|
{
|
|
key: "Cache-Control",
|
|
value: "public, max-age=31536000, immutable",
|
|
},
|
|
],
|
|
},
|
|
];
|
|
},
|
|
};
|
|
|
|
export default nextConfig;
|