microsoft / microsoft/aspire.dev
Homepage emits og:type=article; should be website
Nobody has claimed this yet.
- Dominant language
- MDX
- Stars
- 195
- Forks
- 87
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 73
Description
Summary
The homepage serves og:type=article. The homepage should declare og:type=website for correct entity/social typing, which also aligns with the WebSite schema entity already emitted on the page.
Evidence
- Live
https://aspire.dev/<head>contains<meta property="og:type" content="article">(emitted by Starlight'sDefaultHead). - The site already computes the correct value:
resolveOgType()insrc/frontend/src/utils/page-metadata.ts(lines ~156–178) returns'website'for the home page and anytemplate: splashpage, andgetOgMetadata()surfaces it astype.
Root cause / where the change goes
getOgMetadata().type is computed but never emitted, so Starlight's hardcoded og:type=article wins. The head-optimization middleware only upserts og:title and og:description:
src/frontend/src/route-data-middleware.ts—optimizeOpenGraphHead()(lines ~116–128) callsupsertMetaEntry(head, 'property', 'og:title', og.ogTitle)and... 'og:description', og.description), but notog:type.
Fix by upserting the type in the same place:
upsertMetaEntry(head, 'property', 'og:type', og.type);
upsertMetaEntry replaces the existing head entry in place (matching on the property attribute), so no duplicate og:type tag is produced. This keeps the middleware as the single source of truth for OG head tags. (Emitting it directly in components/starlight/Head.astro would instead risk a duplicate tag alongside Starlight's default.)
Done when
- Re-scrape / social debugger shows
og:type=websiteon/, while docs/article pages still showarticle. - Optionally add a unit test asserting the
og:typeupsert for a home/splash route vs. an article route.
Source: SEO audit of https://aspire.dev/ (2026-07-29). Priority: Medium.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in src/frontend/src/route-data-middleware.ts at optimizeOpenGraphHead(), then read resolveOgType() and getOgMetadata() in src/frontend/src/utils/page-metadata.ts. Add the missing og:type upsert alongside og:title and og:description, and verify that the homepage or splash route emits website while article pages remain article; add the optional unit test if the project’s test setup supports it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- web-dev
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 88/100