Skip to content

chore(headings): fail CI when a heading has no explicit id - #4745

Merged
thetaPC merged 1 commit into
mainfrom
link-check
Sep 22, 2026
Merged

thetaPC merged 1 commit into
mainfrom
link-check

Conversation

@thetaPC

@thetaPC thetaPC commented Sep 22, 2026

Copy link
Copy Markdown
Contributor

Issue URL: internal

What is the current behavior?

Renaming a heading silently moves its anchor and breaks every inbound link, and nothing catches it. Docusaurus has no option to require explicit heading ids, so a page whose headings are all unpinned builds clean. Broken links and anchors only warn.

What is the new behavior?

  • CI runs Docusaurus's own write-heading-ids and fails if it had anything to add, so the generator is both the check and the fix: npm run heading-ids
  • onBrokenLinks and onBrokenAnchors now throw

Does this introduce a breaking change?

  • Yes
  • No

Other information

The CI check covers docs/ only.

@vercel

vercel Bot commented Sep 22, 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 22, 2026 5:59pm UTC

Request Review

@thetaPC
thetaPC marked this pull request as ready for review September 22, 2026 18:29
@thetaPC
thetaPC requested a review from a team as a code owner September 22, 2026 18:29
@thetaPC
thetaPC requested a review from ShaneK September 22, 2026 18:29
@thetaPC
thetaPC merged commit b9cfc56 into main Sep 22, 2026
7 checks passed
@thetaPC
thetaPC deleted the link-check branch September 22, 2026 22:03

This branch was successfully deployed

1 active deployment
Preview — c44f4921 Deployed Sep 22, 2026 by vercel[bot]
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.

2 participants