Initial upload of BB-Apartment 2026 website.
Adds the complete Next.js website including i18n routing, house and apartment pages, Beds24 v2 integration for live availability/pricing, Stripe checkout, contact forms, Docker setup and deployment docs. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
parent
232770afe7
commit
2b24334bfa
@@ -0,0 +1,50 @@
|
||||
import { MetadataRoute } from "next";
|
||||
import { houses } from "@/src/config/apartments";
|
||||
|
||||
const baseUrl = "https://bb-apartment.de";
|
||||
|
||||
export default function sitemap(): MetadataRoute.Sitemap {
|
||||
const locales = ["de", "en"];
|
||||
|
||||
const staticRoutes: MetadataRoute.Sitemap = [
|
||||
{ url: baseUrl, lastModified: new Date() },
|
||||
...locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}`,
|
||||
lastModified: new Date(),
|
||||
})),
|
||||
...locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}/houses`,
|
||||
lastModified: new Date(),
|
||||
})),
|
||||
...locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}/contact`,
|
||||
lastModified: new Date(),
|
||||
})),
|
||||
...locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}/imprint`,
|
||||
lastModified: new Date(),
|
||||
})),
|
||||
...locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}/privacy`,
|
||||
lastModified: new Date(),
|
||||
})),
|
||||
];
|
||||
|
||||
const houseRoutes: MetadataRoute.Sitemap = houses.flatMap((house) =>
|
||||
locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}/houses/${house.slug}`,
|
||||
lastModified: new Date(),
|
||||
}))
|
||||
);
|
||||
|
||||
const apartmentRoutes: MetadataRoute.Sitemap = houses.flatMap((house) =>
|
||||
house.apartments.flatMap((apartment) =>
|
||||
locales.map((locale) => ({
|
||||
url: `${baseUrl}/${locale}/apartments/${apartment.slug}`,
|
||||
lastModified: new Date(),
|
||||
}))
|
||||
)
|
||||
);
|
||||
|
||||
return [...staticRoutes, ...houseRoutes, ...apartmentRoutes];
|
||||
}
|
||||
Reference in New Issue
Block a user