Repository navigation
feat(flame): add meta.verification for site-verification meta tags - #488
Merged
Merged
Conversation
The Algolia Crawler verifies a domain through a <meta name="algolia-site-verification" content="..."> tag in the static HTML of the home page, and Google Search Console works the same way. Flame had no way to add one: plugins only reach docs pages through injectHead, and the Algolia plugin injects nothing on the landing page. docu.json now accepts meta.verification, a map from meta name to token. htmlShell (html.ts and html.shared.ts) writes each entry after the description meta, escaped and trimmed, skipping entries whose name or token is not a non-empty string. Both builds pass it for docs, landing and 404 pages, and the dev server for every page it renders. The schema declares the field with a meta-name pattern, and the configuration and Algolia docs explain how to verify a domain with it.
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes
Mode: standard. I reviewed the whole diff for the new meta.verification config field. That covers rendering, call sites, schema, tests and docs. Overall this is ready to merge.
verificationTags()helper: it lives inhtml.shared.tsand both shells share it.html.tspassesBun.escapeHTMLandhtml.shared.tspassesescapeHtml, so Bun and Node/Deno output match, as the runtime-parity rule requires. Names and tokens are trimmed and escaped, and entries that are not strings or are empty are skipped. That matters becauseloadDocuConfig()inpaths.tsonly runsJSON.parseondocu.json, so this helper is the only check at runtime. WideningHtmlShellOptions.verificationtoRecord<string, unknown>is the right call.- Call sites: every
htmlShellcaller passes the field. That is the docs page, landing page and 404 page in bothbuild.tsandbuild.impl.ts, pluscreateHtmlResponseinserver-routes.tsfor the dev server. A grep found no other callers, so no page is left without the tag. - Build cache:
configStamp()incache-key.tsalready hashes the full resolveddocu.json. Changing a token therefore re-renders every page, andBUILD_CACHE_VERSIONdoes not need a bump. - Schema and types:
DocuMeta.verificationand thedocu.schema.jsonentry agree. Without the schema entry, editors would flag the field, becausemetasetsadditionalProperties: false. ThepropertyNamespattern accepts real provider names such asmsvalidate.01and rejects quotes and spaces. - Tests: they cover tag order, trimming, XSS escaping of both the name and the token, skipped entries, no output when the field is absent, the schema shape, and dev-server output on the home and 404 pages.
- Docs and changeset: the
#site-verificationand#experimentalanchors resolve. The caveat aboutexperimental.pagesis accurate, because no landing page is built in that mode. The@docubook/flameminor changeset is in place.
Top priorities: none. No CRITICAL, HIGH or MEDIUM findings passed the admission rules.
claude-opus-5-5 | 𝕏
This was referenced Nov 6, 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.

Summary
Adds
meta.verificationtodocu.json. With it, the Algolia Crawler can verify the site's domain through a meta tag, and so can Google Search Console and similar services. Each entry, keyed by meta name, becomes a<meta>tag in the<head>of every page Flame builds.{ "meta": { "verification": { "algolia-site-verification": "ADCCB4B3D3A8BDCE" } } }renders
Why
The Algolia Crawler verifies a domain by looking for
<meta name="algolia-site-verification">in the static HTML of the home page. It ignores a tag added by Google Tag Manager. Flame had no way to add such a tag:injectHeaddoes reach every page.@docubook/plugin-search-algoliainjects only on docs pages, so the landing page at/had nothing.metanext totitle,baseURLandogImage.Change
DocuMeta.verification:Record<string, string>, meta name → token.htmlShell(html.tsfor Bun,html.shared.tsfor Node/Deno) gets averificationoption and a sharedverificationTags()helper.<meta name="description">.meta.verificationfor docs pages, the landing page and the 404 page.server-routes.ts) passes it for every page it renders.docu.schema.jsondeclaresmeta.verification: an object whose property names match^[A-Za-z0-9._:-]+$and whose values are non-empty strings. Before,metahadadditionalProperties: false, so editors flagged the field.configuration.mdxgets averificationrow and a "Site verification" section. It covers theexperimental.pagescase, where the home page is the project's own: add the tag there, or give the service a docs page URL (Algolia's "Optional URL").docu.jsonsnippet and the Verify now step.@docubook/flameminor. It joins the pending 2.6.0 release.Verification
algolia-site-verificationandgoogle-site-verificationset.flame buildon Bun and on Node writes both tags intoindex.html(landing),docs/index.html,docs/getting-started/overview.htmland404.html.flame devserves the tag on/,/docs, a docs page and an unknown path (404).docu.jsonchange invalidates the build cache.turbo build --filter=@docubook/flame...passes. The new Configuration and Algolia sections render with their code blocks.scripts/flame-browser-smoke.mjspasses (5 pages).oxlint, andtsc --noEmitpass."><script>;scripts/check-release-plan.mjs(6 scenarios) pass.After merge
To verify docubook.pro, add the code from Algolia's Domains → Meta tag tab to
packages/flame/docu.jsonundermeta.verification, deploy, then click Verify now.