ADS-110: Introduce versioning for the Ads documentation (freeze v1, restructure as v2)#739
Draft
MaartenRimaux wants to merge 1 commit into
Draft
ADS-110: Introduce versioning for the Ads documentation (freeze v1, restructure as v2)#739MaartenRimaux wants to merge 1 commit into
MaartenRimaux wants to merge 1 commit into
Conversation
Contributor
|
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.
ADS-110 — Introduce versioning for the Ads documentation
Freezes the current Ads docs (legacy Signaling Service product) as v1 and makes the working copy v2, mirroring the THEOlive versioning setup. This is the foundation for the Ads docs restructure (epic ADS-98). Targets the long-lived restructure branch
ads-docs-v2.Changes
ads_versioned_docs/version-v1/docusaurus docs:version:ads v1(incl. frozenapi/ads-client.swagger.json; generated API.mdxstays gitignored and is rebuilt from the frozen spec)ads_versioned_sidebars/version-v1-sidebars.json/ads/v1/...(mirrors THEOlive v1 sidebar)ads_versions.jsonv1docusaurus.config.ts— ads pluginlastVersion: 'current',versions: { current: { label: 'v2' }, v1: { label: 'v1', banner: 'none' } }docusaurus.config.ts—ads-apiopenapi pluginv2; newsignalingV1entry generating the legacy Signaling Service reference from the frozen spec into the versioned dir (mirrorstheoLiveV1OpenApiOptions)docusaurus.config.ts— navbardocsVersionDropdownfor theadsplugin (auto-hidden off/ads/routes by the existing swizzled wrapper)docusaurus.config.ts—createRedirects/ads/v1/<page>gains an/ads/<page>origin, so old deep links keep resolving once v2 pages move during the restructurepackage.jsongen-api-docs/clean-api-docsuse--all-versionsforads-api(mirrorstheolive-api).prettierignoreads_versioned_docs/*/api/outputDecision log
ads-docs-v2(as suggested in the ticket); this PR targets it, notmain. Alternative: ticket-prefixed name — rejected to keep the branch product-scoped for the whole epic.createRedirectscovers all of/ads/v1/, not just the API subtree (THEOlive only covers/theolive/v1/api/): the whole Ads doc tree will move during the restructure. While v1 ≡ v2, colliding redirect origins are filtered by@docusaurus/plugin-client-redirectswith a warning (onDuplicateRoutes: 'warn'default) — verified in the plugin source; they activate automatically as v2 pages move.redirectsAds.jsonunchanged: existing/theoads/...→/ads/...entries chain through the new rule once v2 pages move. Note for later restructure tickets: the plugin validates statictotargets, so those entries must be revisited when v2 pages are removed.noIndexon v1: mirrors THEOlive v1 exactly (banner: 'none'only), per ticket.static/copy: defaultdocs:versionbehavior; the liveads/staticremains the served dir. Restructure tickets must keep referenced files (e.g. GAM template) available.Validation
npm run typecheck✅ (after fullgen-api-docs)npm run lint✅npm run check-format✅npx docusaurus gen-api-docs all --plugin-id ads-api --all-versions✅ regenerates the v1 reference from the frozen specnpm run buildnot run (skipped by request — heavy submodule init); PR preview CI should confirm both versions renderBefore merging
/ads/renders labeled v2 with version dropdown/ads/v1/renders incl. Signaling Service API referenceonBrokenLinks: 'throw')Follow-ups
redirectsAds.jsonstatic targets when v2 pages are removedTicket: ADS-110 (parent epic ADS-98)