/** @type {import('next').NextConfig} */
const nextConfig = {
  reactStrictMode: true,
  // Skip ESLint during production builds on hosts that don't install devDependencies
  eslint: {
    ignoreDuringBuilds: true,
  },
  // Optional: if your host blocks TypeScript dev deps, you can temporarily un-comment
  // the block below to skip type-checking during builds.
  // typescript: {
  //   ignoreBuildErrors: true,
  // },
  webpack: (config, { dev }) => {
    // Disable webpack cache in development mode to prevent cache corruption issues
    if (dev) {
      config.cache = false;
    }
    return config;
  },
  // Production specific settings
  poweredByHeader: false, // Remove X-Powered-By header
  compress: true, // Enable gzip compression
  generateEtags: true, // Enable ETag generation
  productionBrowserSourceMaps: false, // Disable source maps in production
  // Turbopack specific settings
  experimental: {
    turbo: {
      rules: {
        // Add any Turbopack-specific rules here
      }
    }
  }
}

module.exports = nextConfig 