← back to Sdcc Awards
cypressaward/frontend/next.config.js
41 lines
/** @type {import('next').NextConfig} */
const nextConfig = {
basePath: '/cypressaward',
assetPrefix: '/cypressaward',
reactStrictMode: true,
swcMinify: true,
images: {
domains: ['localhost', 'cypresawards.org', 'greendomainbrokers.com'],
},
async rewrites() {
return [
{
source: '/api/:path*',
destination: `${process.env.NEXT_PUBLIC_API_URL || 'http://localhost:3001'}/:path*`,
},
];
},
async headers() {
return [
{
source: '/:path*',
headers: [
{
key: 'X-Frame-Options',
value: 'DENY',
},
{
key: 'X-Content-Type-Options',
value: 'nosniff',
},
{
key: 'Referrer-Policy',
value: 'origin-when-cross-origin',
},
],
},
];
},
};
module.exports = nextConfig;