ci(docs): add docs.page link check to docs workflow - #9214
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #9214 +/- ##
============================================
+ Coverage 68.36% 68.39% +0.03%
- Complexity 1914 1915 +1
============================================
Files 516 516
Lines 37853 37853
Branches 5183 5183
============================================
+ Hits 25875 25886 +11
+ Misses 10187 10179 -8
+ Partials 1791 1788 -3
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
russellwheatley
left a comment
There was a problem hiding this comment.
Two things before merge. The AuthSettings fragment drop is a real docs regression. The TypeDoc host gap is bigger: with the current CLI, this job will not fail on a broken reference.rnfirebase.io URL after merge.
| Ensure that all parts of step 1 and 2 from [the official firebase Android phone auth docs](https://firebase.google.com/docs/auth/android/phone-auth#enable-phone-number-sign-in-for-your-firebase-project) have been followed. | ||
|
|
||
| To bypass Play Integrity for manual testing, you may [force reCAPTCHA to be used](https://reference.rnfirebase.io/_react-native-firebase/auth/FirebaseAuthTypes/AuthSettings.html#appVerificationDisabledForTesting) prior to calling [`verifyPhoneNumber`](https://reference.rnfirebase.io/_react-native-firebase/auth/verifyPhoneNumber.html). | ||
| To bypass Play Integrity for manual testing, you may [force reCAPTCHA to be used](https://reference.rnfirebase.io/_react-native-firebase/auth/AuthSettings.html) prior to calling [`verifyPhoneNumber`](https://reference.rnfirebase.io/_react-native-firebase/auth/verifyPhoneNumber.html). |
There was a problem hiding this comment.
The iOS AuthSettings link a few lines up still deep-links to #appverificationdisabledfortesting. This Android one dropped the fragment, so it lands on the interface page instead of the property. Restore the same hash.
| "lint:ios:check": "find packages/*/ios -type f \\( -name '*.h' -o -name '*.cpp' -o -name '*.m' -o -name '*.mm' \\) -not -path '*/generated/*' -print0 | xargs -0 clang-format --style=Google -n -Werror", | ||
| "lint:ios:fix": "find packages/*/ios -type f \\( -name '*.h' -o -name '*.cpp' -o -name '*.m' -o -name '*.mm' \\) -not -path '*/generated/*' -print0 | xargs -0 clang-format -i --style=Google", | ||
| "lint:markdown": "eslint \"docs/**/*.mdx\" --max-warnings=0 && prettier --check \"docs/**/*.mdx\"", | ||
| "lint:docs-links": "docs check . --external-links warn", |
There was a problem hiding this comment.
--external-links warn is the right call for npm/SO 403s. @docs.page/cli treats every https:// URL as external (classifyTarget), and there is no per-host severity. That means a 404 on reference.rnfirebase.io will only warn, which is almost every TypeDoc link this sweep rewrote.
Internal /auth/usage paths, assets, MDX, and frontmatter will still fail the job. TypeDoc URL rot will not.
If the point of wiring this in is to keep those reference links honest, this needs a companion check that fails on that host, or a CLI feature for host-specific severity. As written, the sweep helps today's clicks and then CI stops watching.
Summary
Integrates
@docs.page/cli checkinto RNFB docs validation so broken internal links, missing assets, MDX render issues, and metadata problems fail CI — closing the gap left after the June 2026 link-audit sweep (PR #9051), which fixed URLs but never wired the checker into lint/CI.Two bisectable commits:
migrating-to-v26.mdxem dash) so the checker is green before enforcement landsyarn lint:docs-links,@docs.page/cli@2.0.0devDep,.github/workflows/docs.ymlstep, OKF agent guidanceExternal links: why
--external-links warnonlydocs checkdefaults every category to error. The yarn script isdocs check . --external-links warn— the only override. npmjs.com, Stack Overflow, and similar hosts often return 403 Forbidden to GitHub Actions / automated link checkers even when the URL works in a browser. Treating those as errors would fail CI on false positives.Agents still must fix every error line. OKF documents the sole acceptable non-fix: external warn from bot/WAF blocking (validation-checklist § docs.page link check). Real broken links at error severity must be fixed in normal change authoring.
Test plan
yarn lint:markdownexit 0yarn lint:spellcheckexit 0yarn lint:docs-linksexit 0 (0 errors; external 403s warn-only)Maintainer note: Fixes CPRN-368