Implement Phase 1 of i18n spec: - Configure next-intl with 6 locales (pt, en, es, fr, de, zh-CN) and pathnames - Move routes to app/[locale] structure with localized layouts and metadata - Add middleware for root language negotiation (307), legacy redirects (308), and 404 for non-pt book - Implement language selector dropdown in header with cookie persistence - Add system typography rules for zh-CN and word-break/hyphenation for de/fr Co-Authored-By: Antigravity <noreply@google.com>
22 lines
586 B
JavaScript
22 lines
586 B
JavaScript
import createNextIntlPlugin from "next-intl/plugin";
|
|
|
|
const withNextIntl = createNextIntlPlugin("./i18n/request.js");
|
|
|
|
/** @type {import('next').NextConfig} */
|
|
const nextConfig = {
|
|
// A imagem Docker liga isto (NEXT_OUTPUT=standalone) para empacotar só o que
|
|
// o servidor usa. Fora dela o build continua igual: `next start`/pm2.
|
|
output: process.env.NEXT_OUTPUT === "standalone" ? "standalone" : undefined,
|
|
experimental: {
|
|
optimizePackageImports: [
|
|
"lucide-react",
|
|
],
|
|
},
|
|
images: {
|
|
formats: ["image/avif", "image/webp"],
|
|
},
|
|
};
|
|
|
|
export default withNextIntl(nextConfig);
|
|
|