Files
mb-grid-solutions.com/app/[locale]/page.tsx
Marc Mintel 5fb73d57dd
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 4s
🚀 Build & Deploy / 🚀 Deploy (push) Has been cancelled
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Has been cancelled
🚀 Build & Deploy / 🏗️ Build (push) Has been cancelled
🚀 Build & Deploy / 🔔 Notify (push) Has been cancelled
🚀 Build & Deploy / 🧪 QA (push) Has been cancelled
feat: complete migration to static MDX, stabilize local infrastructure and fix i18n issues
2026-05-04 10:26:45 +02:00

33 lines
1018 B
TypeScript

import React from "react";
import { Metadata } from "next";
import { notFound } from "next/navigation";
import HomeContent from "@/components/HomeContent";
export const metadata: Metadata = {
title: "MB Grid Solutions | Energiekabelprojekte & Technische Beratung",
description:
"Ihr spezialisierter Partner für herstellerneutrale technische Beratung und Projektbegleitung bei Energiekabelprojekten bis 110 kV.",
};
interface PageProps {
params: Promise<{ locale: string }>;
}
export default async function Page({ params }: PageProps) {
const { locale } = await params;
// Dynamically import the MDX content based on locale
let Content: React.ComponentType;
try {
const mdx = await import(`@/content/${locale}/index.mdx`);
Content = mdx.default;
} catch (e) {
// Fallback if MDX is not yet created for this locale
return <HomeContent />;
}
// Render the MDX content.
// We can use mdx-components.tsx to map MDX tags to our high-fidelity sections.
return <Content />;
}