[No QA] Update coding standards index and normalize clean-react ids#93990
Conversation
The coding standards index listed only the rules that existed when it was written. Several rules added since then were missing from both the categories table and the quick reference, including an entire UI category that had no entry at all. Add a UI category and list the new UI, consistency, and clean-react rules so the index reflects every rule file in the directory.
|
@Julesssss this is the follow-up you asked for - adding the new rules to the coding-standards index. It turned out the index was missing more than just the UI rules: there was no UI section at all (even the existing The four newest clean-react rules use the id prefix |
|
CC @rlinoz as @Julesssss is OOO today 🙏 |
The four newest clean-react rules used the id prefix CLEAN-REACT- while the established rules and the category use CLEAN-REACT-PATTERNS-. Align the four new rules (ruleId frontmatter and section headers) with the existing convention, and update the index and category table to match. Filenames already follow the shared clean-react-N convention, so they are unchanged.
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safari |
|
Sorry for the ping, no need to review, thanks! |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/rlinoz in version: 9.4.16-1 🚀
Bundle Size Analysis (Sentry): |
|
🚀 Deployed to production by https://github.com/blimpich in version: 9.4.16-5 🚀
|
Explanation of Change
This PR does two related things to the coding-standards skill: it brings the index back in sync with the rule files, and it normalizes the clean-react rule ids to a single convention.
The coding-standards index (
.claude/skills/coding-standards/SKILL.md) lists every rule in both a categories table and a quick reference. Several rules added to.claude/skills/coding-standards/rules/after the index was written were never added to it, including an entireUIcategory that had no entry at all (not even the pre-existingUI-1rule).This PR updates the index so it reflects every rule file in the directory:
UIcategory row to the categories table.CONSISTENCY-7..11,CLEAN-REACT-PATTERNS-6..9, and a newUIsection withUI-1..3.ConsistencyandClean React Patternscategory descriptions to mention the newly covered areas (localization, file naming, JSDoc, prop typing, function components).It also normalizes the four newest clean-react rules, which used the id prefix
CLEAN-REACT-, to the establishedCLEAN-REACT-PATTERNS-convention used by the other rules and the category. This updates theirruleIdfrontmatter, their section headers, the category table prefix, and the index entries. The filenames already follow the sharedclean-react-Nconvention and are unchanged.Verified that every file in
rules/is now referenced by the index and that everyrules/*.mdlink resolves.Fixed Issues
$ #94020
PROPOSAL:
Tests
.claude/skills/coding-standards/SKILL.mdand confirm the categories table includes aUIrow.CONSISTENCY-7..11,CLEAN-REACT-6..9, andUI-1..3.for f in .claude/skills/coding-standards/rules/*.md; do grep -q "$(basename "$f")" .claude/skills/coding-standards/SKILL.md || echo "MISSING: $f"; donegrep -oE 'rules/[a-z0-9-]+\.md' .claude/skills/coding-standards/SKILL.md | sort -u | while read p; do [ -f ".claude/skills/coding-standards/$p" ] || echo "BROKEN: $p"; doneOffline tests
N/A - this change updates a documentation index file only; it does not affect runtime or offline behavior.
QA Steps
N/A - there is no user-facing or staging behavior to QA. The change updates the coding-standards index file only.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)Avatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari