import type { NextConfig } from 'next' const nextConfig: NextConfig = { serverExternalPackages: ['pdf-parse'], devIndicators: false, images: { remotePatterns: [ { protocol: 'https', hostname: 'images.marblecms.com', }, { protocol: 'https', hostname: 'lh3.googleusercontent.com', }, { protocol: 'https', hostname: 'avatars.githubusercontent.com', }, ], }, async rewrites() { return [ { source: '/ingest/static/:path*', destination: 'https://eu-assets.i.posthog.com/static/:path*', }, { source: '/ingest/:path*', destination: 'https://eu.i.posthog.com/:path*', }, { source: '/ingest/decide', destination: 'https://eu.i.posthog.com/decide', }, { source: '/privacy-policy', destination: '/privacy', }, { source: '/terms-of-service', destination: '/terms', }, ] }, // This is required to support PostHog trailing slash API requests skipTrailingSlashRedirect: true, } export default nextConfig