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 ruleP2stack specificStack: css
csscross-browserscrollbar
Hide scrollbars with cross-browser CSS
When hiding a scrollbar, include the Firefox-specific declaration (or a shared mixin) so it works in every browser.
PR: hegnar-forum-web · org-mining-hist-2026-06Created: Jun 20, 2026
Bad example
Old codecss
| 1 | .scroller { |
| 2 | overflow-y: auto; |
| 3 | &::-webkit-scrollbar { display: none; } |
| 4 | } |
Explanation (EN)
Objašnjenje (HR)
Good example
New codecss
| 1 | .scroller { |
| 2 | overflow-y: auto; |
| 3 | scrollbar-width: none; /* Firefox */ |
| 4 | &::-webkit-scrollbar { display: none; } |
| 5 | } |
Explanation (EN)
Objašnjenje (HR)