fix(next): disable trailingSlash to restore API route matching for /api/auth/*

This commit is contained in:
Haitao Pan 2025-11-01 23:14:12 +08:00
parent 91b32e8a48
commit 163ae0f5c4

View File

@ -48,7 +48,7 @@ const shouldUseStaticExport = process.env.NEXT_SHOULD_EXPORT === 'true'
/** @type {import('next').NextConfig} */
const nextConfig = {
...(shouldUseStaticExport ? { output: 'export' } : {}),
trailingSlash: true,
trailingSlash: false,
reactStrictMode: true,
compress: false, // 压缩交给 Nginx省 Node CPU
images: { unoptimized: true }, // 关闭服务端图片处理