23 lines
481 B
JavaScript
23 lines
481 B
JavaScript
import { withPayload } from '@payloadcms/next/withPayload'
|
|
|
|
/** @type {import('next').NextConfig} */
|
|
const nextConfig = {
|
|
// Your Next.js config here
|
|
async rewrites() {
|
|
return [
|
|
{
|
|
source: '/((?!admin|api))tenant-domains/:path*',
|
|
destination: '/tenant-domains/:tenant/:path*',
|
|
has: [
|
|
{
|
|
type: 'host',
|
|
value: '(?<tenant>.*)',
|
|
},
|
|
],
|
|
},
|
|
]
|
|
},
|
|
}
|
|
|
|
export default withPayload(nextConfig)
|