feat: add SEO and LLM discoverability infrastructure#593
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds SEO- and crawler-friendly infrastructure around the generated UI5 TypeScript API reference site by improving per-page metadata and generating top-level index/sitemap/LLM discovery artifacts during the gh-pages publish workflow.
Changes:
- Add Open Graph meta tags to generated API HTML pages and include
<lastmod>in per-version sitemap entries. - Introduce a Node.js generator script to produce
api/index.html, per-framework index pages, a site-root sitemap index, andapi/llms.txt. - Update the GitHub Actions workflow to call the generator script and commit the new site-root
sitemap.xml.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| scripts/generate-api-docs/generate.mjs | Adds OG meta tags and <lastmod> for generated per-version sitemaps. |
| scripts/generate-api-docs/generate-index-pages.mjs | New script generating API landing pages, sitemap index, and llms.txt. |
| .github/workflows/generate-api-docs.yml | Replaces inline shell HTML generation with the new Node script; commits site-root sitemap. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- generate-index-pages.mjs: new Node.js script replacing shell heredoc
HTML templating in the workflow. Generates:
- api/index.html and api/{framework}/index.html (with meta description + OG tags)
- sitemap.xml (sitemap index at site root)
- api/llms.txt (structured overview for LLM crawlers)
- generate.mjs: add Open Graph meta tags to htmlTemplate() and
<lastmod> dates to per-version sitemap entries
- workflow: replace inline shell HTML generation with script call,
add sitemap.xml to git add scope
b43a0c5 to
c29ced6
Compare
TypeDoc merges all .d.ts files into one documentation set, causing the shared 'sap' namespace to duplicate content across library directories. For example, sap.f/namespaces/sap/namespaces/m/ contained sap.m classes, and sap.f/sap/tnt/ contained sap.tnt enums (from a module augmentation). The fix collects which modules each .d.ts file declares, then excludes pages that either: - Don't match any declared module (namespace re-export artefacts) - Match a module whose namespace belongs to another library (augmentation) This removes ~54 duplicate pages per library that had cross-library content, reducing confusion and improving the signal-to-noise ratio for crawlers.
6bf6602 to
5b9e9bc
Compare
…okup - generate-index-pages.mjs: strip trailing slashes from --base-url to prevent double-slash URLs in canonical links and sitemaps - generate.mjs: replace O(N) module scan in shouldExclude() with O(1) Set.has() lookups by deriving the module path from directory prefixes
npm show with a version range (e.g. ~1.136.0) outputs lines like '@openui5/types@1.136.17 '1.136.17'' instead of just '1.136.17'. Extract the bare semver with grep to avoid malformed version strings that fail the downstream validation.
codeworrior
reviewed
Jun 16, 2026
- Workflow: version floor now uses major >= 2 || (major === 1 && minor >= 120) instead of just minor >= 120, which would exclude future 2.x versions. - generate.mjs: clarify the shouldExclude comment per review feedback.
codeworrior
approved these changes
Jun 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
generate-index-pages.mjs: new Node.js script replacing shell heredoc HTML templating in the workflow. Generates:
generate.mjs: add Open Graph meta tags to htmlTemplate() and dates to per-version sitemap entries
workflow: replace inline shell HTML generation with script call, add sitemap.xml to git add scope