- Add 4-locale keyword configurations (SR, EN, DE, FR) - Create schema generators (Product, Organization, Breadcrumb) - Add React components for JSON-LD rendering - Implement caching for keyword performance - Abstract all SEO logic for maintainability
42 lines
1.0 KiB
TypeScript
42 lines
1.0 KiB
TypeScript
import { JsonLd } from './JsonLd';
|
|
import { generateOrganizationSchema, generateWebSiteSchema } from '@/lib/seo/schema/organizationSchema';
|
|
import { Locale } from '@/lib/seo/keywords/types';
|
|
|
|
interface OrganizationSchemaProps {
|
|
baseUrl: string;
|
|
locale: Locale;
|
|
logoUrl: string;
|
|
socialProfiles?: string[];
|
|
email?: string;
|
|
}
|
|
|
|
/**
|
|
* Organization schema component
|
|
* Renders Organization + WebSite JSON-LD schemas
|
|
*
|
|
* @param baseUrl - Site base URL
|
|
* @param locale - Current locale
|
|
* @param logoUrl - URL to organization logo
|
|
* @param socialProfiles - Array of social media profile URLs
|
|
* @param email - Contact email
|
|
*/
|
|
export function OrganizationSchema({
|
|
baseUrl,
|
|
locale,
|
|
logoUrl,
|
|
socialProfiles,
|
|
email,
|
|
}: OrganizationSchemaProps) {
|
|
const orgSchema = generateOrganizationSchema(baseUrl, locale, {
|
|
logoUrl,
|
|
socialProfiles,
|
|
email,
|
|
});
|
|
|
|
const websiteSchema = generateWebSiteSchema(baseUrl, locale);
|
|
|
|
return <JsonLd data={[orgSchema, websiteSchema]} />;
|
|
}
|
|
|
|
export default OrganizationSchema;
|