Skip to content

Add schema.org breadcrumbs for docs, share one component with handbook - #5578

Merged
Yndira-E merged 1 commit into
mainfrom
zj-breadcrumbs-json-ld
Aug 12, 2026
Merged

Add schema.org breadcrumbs for docs, share one component with handbook#5578
Yndira-E merged 1 commit into
mainfrom
zj-breadcrumbs-json-ld

Conversation

@ZJvandeWeg

Copy link
Copy Markdown
Member

Docs had no BreadcrumbList structured data at all - just a plain

built from raw URL segments (no real page titles). Handbook had schema markup, but via a call duplicated in the page's script, separate from the visual breadcrumb component, and both were subtly wrong: nuxt/content's findPageBreadcrumb() excludes the current page by default, so the existing .slice(0, -1) (meant to drop the current page) was actually dropping the true parent crumb, and the current page was never in the schema at all.

Fixes:

  • New shared nuxt/components/Breadcrumbs.vue renders the visual trail and registers the matching BreadcrumbList in one place, so a page can't show one without the other going stale. Every crumb gets a ListItem (including the current page) - schema.org only makes item optional for the last entry, not the entry itself.
  • Renamed DocsNavNode's name field to title, matching @nuxt/content's ContentNavigationItem shape, so docs can reuse @nuxt/content's own findPageBreadcrumb() (via a small findDocsBreadcrumb() flatten-and- delegate wrapper, since groups themselves aren't pages) instead of a bespoke tree walker.
  • Extracted useDocsNavTree() so the docs page and DocsLeftNav share one useAsyncData('docs-nav', ...) call - they'd started emitting a "did you mean to use a different handler" dev warning once both called it.
  • Docs breadcrumbs now show real page titles instead of raw URL segments.

Verified locally: /docs/admin/sso/ldap and /handbook/design/design-thinking both render the correct visible trail and a complete BreadcrumbList with position 1..N, terminating in the current page.

Checklist

  • I have read the contribution guidelines
  • I have considered the performance impact of these changes
  • Suitable unit/system level tests have been added and they pass
  • Documentation has been updated
  • For blog PRs, an Art Request has been created (instructions)

Docs had no BreadcrumbList structured data at all - just a plain <nav>
built from raw URL segments (no real page titles). Handbook had schema
markup, but via a call duplicated in the page's script, separate from
the visual breadcrumb component, and both were subtly wrong: nuxt/content's
findPageBreadcrumb() excludes the current page by default, so the existing
`.slice(0, -1)` (meant to drop the current page) was actually dropping the
true parent crumb, and the current page was never in the schema at all.

Fixes:
- New shared nuxt/components/Breadcrumbs.vue renders the visual trail and
  registers the matching BreadcrumbList in one place, so a page can't
  show one without the other going stale. Every crumb gets a ListItem
  (including the current page) - schema.org only makes `item` optional
  for the last entry, not the entry itself.
- Renamed DocsNavNode's `name` field to `title`, matching @nuxt/content's
  ContentNavigationItem shape, so docs can reuse @nuxt/content's own
  findPageBreadcrumb() (via a small findDocsBreadcrumb() flatten-and-
  delegate wrapper, since groups themselves aren't pages) instead of a
  bespoke tree walker.
- Extracted useDocsNavTree() so the docs page and DocsLeftNav share one
  useAsyncData('docs-nav', ...) call - they'd started emitting a "did you
  mean to use a different handler" dev warning once both called it.
- Docs breadcrumbs now show real page titles instead of raw URL segments.

Verified locally: /docs/admin/sso/ldap and /handbook/design/design-thinking
both render the correct visible trail and a complete BreadcrumbList with
position 1..N, terminating in the current page.
@ZJvandeWeg
ZJvandeWeg requested a review from Yndira-E August 11, 2026 17:58
@netlify

netlify Bot commented Aug 11, 2026

Copy link
Copy Markdown

Deploy Preview for flowforge-website ready!

Name Link
🔨 Latest commit 9c31253
🔍 Latest deploy log https://app.netlify.com/projects/flowforge-website/deploys/6a7b62b03ee071000821a188
😎 Deploy Preview https://deploy-preview-5578--flowforge-website.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 62 (🔴 down 2 from production)
Accessibility: 96 (no change from production)
Best Practices: 100 (no change from production)
SEO: 85 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

@Yndira-E
Yndira-E merged commit 861ddef into main Aug 12, 2026
7 checks passed
@Yndira-E
Yndira-E deleted the zj-breadcrumbs-json-ld branch August 12, 2026 08:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants