Rules Hub
Coding Rules Library
← Back to all rules
Rule priority, scope & exceptions
Use this to align rules with the senior-level structure (P0/P1/P2, scope, exceptions/tradeoffs).
frontend ruleP2universalStack: universal
codemodrefactoringsearch-replace
Account for spacing variants when running automated find-and-replace
A codemod or search-replace keyed on exact tokens (e.g. '1rem') will miss spaced variants ('1 rem'); broaden the match or do a manual sweep.
PR: hegnar-web · org-mining-hist-2026-06Created: Jun 19, 2026
Bad example
Old codecss
| 1 | // comment slipped through codemod that only matched `1rem` |
| 2 | // 1 rem on the grid element + 1 rem on each column |
Explanation (EN)
Objašnjenje (HR)
Good example
New codecss
| 1 | // also catch spaced variants like `1 rem` and update them |
| 2 | // 0.75rem on the grid element + 0.75rem on each column |
Explanation (EN)
Objašnjenje (HR)