Skip to content

chore(v5): rename archived v5 pages to .mdx - #4700

Open
thetaPC wants to merge 1 commit into
mainfrom
FW-6456-pt10
Open

chore(v5): rename archived v5 pages to .mdx#4700
thetaPC wants to merge 1 commit into
mainfrom
FW-6456-pt10

Conversation

@thetaPC

@thetaPC thetaPC commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Issue URL: internal

What is the current behavior?

Every live doc page has moved to .mdx as part of the Strict MDX migration, but the archived versions were deliberately left alone, since they are never built.

That holds only while they stay archived. Most of these pages are MDX in everything but name: 342 of v5's 460 pages contain imports and 306 contain JSX. Once Strict MDX is enabled, reviving this version would parse those as plain CommonMark, turning every import into a line of literal text on the page. It would not fail the build, so the first sign of trouble would be a reader seeing an import statement in the middle of a paragraph.

Archived versions are revivable by design: the archiving guide already documents moving one back into versions.json. So leaving them behind converts a documented, supported operation into one that silently produces broken pages.

What is the new behavior?

v5 is migrated to match the live versions: all 460 pages renamed, along with 510 component API imports and 192 internal links.

Nothing about the archived state changes. v5 stays in versionsArchived.json, stays out of versions.json, and is still not built. This only makes it safe to revive later.

Two differences from the v7 and v6 PRs are worth knowing, because they change what a reviewer should expect.

v5 has no playground partials and no README, so the whole change is pages, component API imports and internal links. Every page is renamed, with no exclusions.

More importantly, v5's native/ and cli/commands/ directories are committed content, not generated output. v6 through v8 each carry a .gitignore in those directories and track nothing inside them. v5 has no such file and tracks 191 pages under native/ and 53 under cli/commands. They are not regenerable: webengage, for example, does not appear anywhere in scripts/native.mjs, and the generator produces 24 plugin pages against v5's 191. These are legacy Cordova and Ionic Native pages that nothing has rewritten in years. They are ordinary source files that happen to sit in a directory whose name matches a generated one in later versions, so they are renamed with everything else.

Does this introduce a breaking change?

  • Yes
  • No

Other information

This is the last of three, after v7 and v6. The three are independent, since each touches only its own version tree, so they can merge in any order.

All three land before the transitional compatibility code is removed, and that order matters. These archived pages currently import 425 component API partials by their .md names, which only resolve because the plugin still writes both. Removing that first would leave the archived versions broken and then fix them afterwards. Doing the versions first means nothing anywhere imports the old names by the time it comes out.

The same work then goes to translation/jp, and reaches major-10.0 through the usual sync.

Verification was done by temporarily reviving the version, since archived pages are otherwise never built and a mistake here would have no signal at all.

How to test

Archived versions are not built, so nothing in a normal preview exercises these pages. To check them, revive the version locally:

  1. Move v5 out of versionsArchived.json and back into versions.json.
  2. Run npm run generate-markdown, then npx docusaurus build with no --locale flag.
  3. Revert versions.json and versionsArchived.json afterwards. Neither belongs in this PR.

Do not add v5 to the write targets in scripts/native.mjs or scripts/cli.mjs, even though the v7 and v6 instructions say to. Those versions have no committed pages in native/ or cli/commands, so they need the generator to fill them. v5 already has 244 committed pages there, and generating over them produces duplicate routes: it silently drops the v5 page count from 460 to 286 and takes pages with it. That happened on the first attempt at this verification, which is the only reason it is called out here.

The build should complete with no errors, and /docs/v5/ should render 460 pages. Worth spot checking an API page for its generated tables, and one of the legacy plugin pages under native/.

@vercel

vercel Bot commented Sep 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
ionic-docs Ready Ready Preview Sep 3, 2026 5:15pm UTC

Request Review

@thetaPC
thetaPC marked this pull request as ready for review September 3, 2026 17:20
@thetaPC
thetaPC requested a review from a team as a code owner September 3, 2026 17:20
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