feat(seo): describe the site with schema.org JSON-LD - #12598
Conversation
|
This pull request is part of a Mergify stack:
|
Merge Protections🔴 4 of 7 protections blocking · waiting on 👀 reviews, 🤖 CI, ⛓️ dependency and 🙋 you
🔴 ⛓️ Depends-On RequirementsWaiting for
This rule is failing.Requirement based on the presence of
🔴 👀 Review RequirementsWaiting for
This rule is failing.
🔴 🔎 ReviewsWaiting for
This rule is failing.
🟠 🤖 Continuous IntegrationWaiting for any of
Waiting checks:
|
42194cf to
53252e6
Compare
Revision history
|
There was a problem hiding this comment.
Pull request overview
Adds schema.org JSON-LD structured data to the docs site so search engines/assistants can reliably resolve the publisher (Mergify), contact points, product entity, and the current page entity.
Changes:
- Injects a new
StructuredDatacomponent into the global<head>viaBaseLayout.astro. - Introduces
src/components/StructuredData.astroto emit an@graphcontainingOrganization,SoftwareApplication, and eitherWebSite(home) orTechArticle(other pages).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/layouts/BaseLayout.astro | Adds the StructuredData component to the document head so JSON-LD is emitted on pages using this layout. |
| src/components/StructuredData.astro | Defines and inlines the schema.org JSON-LD graph for Organization/Product/Page entities. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
53252e6 to
685d63f
Compare
The docs carried no structured data, so who publishes them, how to contact Mergify and what product they document were all inferable only from prose. Search engines and assistants both use JSON-LD for that entity resolution. Emit one `@graph` per page: an Organization node with the registered address, support and sales contact points and the canonical social profiles; a SoftwareApplication node for the product; and either a WebSite node on the homepage or a TechArticle node for the page itself. The Organization is declared once and referenced by `@id` from the others rather than repeated. Every value is taken from something already published — the footer's social links, the addresses used across the docs, the pricing page. `<` is escaped to its `\u003c` form in the serialized graph. Page titles and descriptions come from frontmatter in this repository, so nothing hostile is expected there, but `JSON.stringify` leaves `</script>` intact and inlining it would end the tag early. Change-Id: Idd84bc050695e27d6d8a361538e2ef89da8dd32e
685d63f to
c8f64c2
Compare
The docs carried no structured data, so who publishes them, how to contact
Mergify and what product they document were all inferable only from prose.
Search engines and assistants both use JSON-LD for that entity resolution.
Emit one
@graphper page: an Organization node with the registered address,support and sales contact points and the canonical social profiles; a
SoftwareApplication node for the product; and either a WebSite node on the
homepage or a TechArticle node for the page itself. The Organization is
declared once and referenced by
@idfrom the others rather than repeated.Every value is taken from something already published — the footer's social
links, the addresses used across the docs, the pricing page.
<is escaped to its\u003cform in the serialized graph. Page titles anddescriptions come from frontmatter in this repository, so nothing hostile is
expected there, but
JSON.stringifyleaves</script>intact and inlining itwould end the tag early.
Depends-On: #12597