Skip to content

Set absolute site url to enable the theme's full SEO output - #453

Open
miharp wants to merge 1 commit into
OpenVoxProject:masterfrom
miharp:config/site-url
Open

Set absolute site url to enable the theme's full SEO output#453
miharp wants to merge 1 commit into
OpenVoxProject:masterfrom
miharp:config/site-url

Conversation

@miharp

@miharp miharp commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

Since jekyll-vitepress-theme 1.9, the theme ships an SEO layer that can emit canonical URLs, JSON-LD, sitemap.xml, a robots.txt sitemap pointer, and llms.txt/llms-full.txt. Without an absolute url in _config.yml most of that is skipped: the build warns every run, no sitemap is generated, and the llms outputs use relative links.

This sets the production origin in _config.yml and updates the canonical_latest plugin to read the origin from site.url rather than only its hardcoded constant. The constant remains as a fallback for builds where url is unset or overridden (jekyll serve rewrites it to localhost in development).

Verified with a full local build:

  • sitemap.xml is generated (920 URLs, absolute) and robots.txt now advertises it
  • pages get self-canonical links and JSON-LD
  • llms.txt links are absolute instead of relative
  • the numbered "latest twin" collections still canonicalize to their /latest/ URLs (e.g. /openvox/8.x/…/openvox/latest/…), so search engines can dedupe the symlinked copies
  • the theme's "Set an absolute url" build warning is gone
  • rubocop clean

Written with AI assistance (Claude, disclosed per the org AI policy); changes reviewed and build-tested locally.

With no absolute url in _config.yml, the theme's SEO layer (added in
jekyll-vitepress-theme 1.9) skips canonical URLs, JSON-LD, and
sitemap.xml, warns on every build, and emits llms.txt with relative
links. Setting the production origin turns all of that on: pages get
self-canonicals, robots.txt advertises the sitemap, and llms.txt links
become absolute.

The canonical_latest plugin now reads the origin from site.url instead
of only its hardcoded constant, which remains as the fallback for
builds where url is overridden or unset (jekyll serve rewrites it to
localhost in development). Its /latest/ canonicals still take
precedence on the numbered twin collections, which search engines can
now use to dedupe the /8.x/ and /latest/ copies.

Co-authored-by: Claude <noreply@anthropic.com>
Signed-off-by: Michael Harp <mike@mikeharp.com>
@miharp
miharp requested a review from a team as a code owner August 21, 2026 11:02
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.

1 participant