Files
erettsegi-browser/next.config.ts
x cf243d46f1 feat: update Next.js configuration and dependencies, add Docker support
- Set output mode to "standalone" in next.config.ts
- Update dependencies in package.json:
  - Upgrade @heroui/react to ^2.8.5
  - Upgrade framer-motion to ^12.23.25
  - Upgrade next to 16.0.7
  - Upgrade react and react-dom to 19.2.1
  - Upgrade undici to ^7.16.0
  - Upgrade devDependencies including @biomejs/biome, @tailwindcss/postcss, and typescript
- Modify error handling in API routes to simplify catch blocks
- Refactor NotFound component for cleaner JSX structure
- Update global CSS imports for consistency
- Change tsconfig to use "react-jsx" for JSX and include additional type definitions
- Add GitHub Actions workflow for Docker image build and push
- Create Dockerfile for multi-stage build process
- Add development and production Docker Compose configurations

ai commit message xd
2025-12-06 01:41:00 +01:00

57 lines
943 B
TypeScript

import type { NextConfig } from "next";
const securityHeaders = [
{
key: "X-DNS-Prefetch-Control",
value: "on",
},
{
key: "X-XSS-Protection",
value: "1; mode=block",
},
{
key: "X-Content-Type-Options",
value: "nosniff",
},
{
key: "Referrer-Policy",
value: "strict-origin",
},
{
key: "Content-Security-Policy",
value: `frame-ancestors 'self';`,
},
{
key: "X-Frame-Options",
value: "SAMEORIGIN",
},
{
key: "Strict-Transport-Security",
value: "max-age=31536000; includeSubDomains; preload",
},
{
key: "Permissions-Policy",
value: "camera=(), microphone=(), geolocation=()",
},
{
key: "X-Source",
value: "github.com/skidoodle/erettsegi-browser",
},
];
const nextConfig: NextConfig = {
async headers() {
return [
{
source: "/:path*",
headers: securityHeaders,
},
];
},
reactStrictMode: true,
poweredByHeader: false,
output: "standalone",
};
export default nextConfig;