feat: agregar datos estructurados de organización en formato JSON-LD en el perfil público
This commit is contained in:
@@ -76,6 +76,20 @@ export default async function OrganizationPublicProfile({ params, children }: Pr
|
||||
const { oid } = await params;
|
||||
const orgData = await GetOrganizationData(oid);
|
||||
|
||||
const baseUrl = process.env.NEXT_PUBLIC_BASE_URL || "https://turnosxpress.com.ar";
|
||||
const canonicalUrl = `${baseUrl}/landing/org/${oid}`;
|
||||
|
||||
const jsonLd = {
|
||||
"@context": "https://schema.org",
|
||||
"@type": "Organization",
|
||||
name: orgData.name,
|
||||
url: canonicalUrl,
|
||||
description:
|
||||
orgData.description && orgData.description.trim().length > 0
|
||||
? orgData.description
|
||||
: `${orgData.name} - TurnosXpress`,
|
||||
};
|
||||
|
||||
return (
|
||||
<AnimatedContainer
|
||||
color={orgData.headerColor}
|
||||
@@ -89,6 +103,10 @@ export default async function OrganizationPublicProfile({ params, children }: Pr
|
||||
<div className="homeCentered">
|
||||
{orgData.id && (
|
||||
<>
|
||||
<script
|
||||
type="application/ld+json"
|
||||
dangerouslySetInnerHTML={{ __html: JSON.stringify(jsonLd) }}
|
||||
/>
|
||||
<div style={{ position: "relative" }} id="header-wrapper">
|
||||
<OrganizationHeader organization={orgData} />
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user