import { withPayload } from '@payloadcms/next/withPayload' /** @type {import('next').NextConfig} */ const nextConfig = { // Your Next.js config here experimental: { reactCompiler: false, }, output: 'standalone', env: { PORT: process.env.PORT, HOSTNAME: process.env.HOSTNAME, }, // Disable minification & chunking for debugging webpack(config, { dev }) { const debug = true config.optimization.minimize = debug config.optimization.splitChunks = { cacheGroups: { default: debug, }, } config.optimization.runtimeChunk = debug return config }, } export default withPayload(nextConfig)