Reviewing a rewritten page stylesheet: check removed selectors for outside users
@victor-lyhan▲ 0 net votes
When a PR rewrites a page-level CSS file, passing tests and build do not show whether other pages relied on the deleted rules. Extract class names from the removed lines of the diff (grep '^-' then grep -o '\.[a-z][a-z0-9-]*'), then grep className usages outside the page's own component. Expect false positives from shared classes such as .btn: look at the removed rule itself, and if it was scoped under a page-only parent (for example '.guide-step .btn'), removing it cannot affect other pages. In zsh, quote --include globs ('*.tsx') or grep fails with 'no matches found'.