Rules Hub
Code Ruleset
Rule priority, scope & exceptions
Use this to align rules with the senior-level structure (P0/P1/P2, scope, exceptions/tradeoffs).
Ensure spacing around inline anchors in text
When an anchor follows plain text in a paragraph, add an explicit space (wrap text in a span with a trailing space or add it to the anchor) so words don't run together; and avoid trailing separators after the last item.
Bad example
| 1 | Kilde: Meteorologisk institutt <a href='...'>met.no</a> |
Explanation (EN)
JSX line boundaries do not always produce the visible word separation the source suggests.
Objašnjenje (HR)
Good example
| 1 | <p>Source:{" "}<a href="/source">Publisher</a></p> |
Explanation (EN)
One explicit space separates the text and link without duplicating whitespace.
Objašnjenje (HR)
Notes (EN)
Inspect rendered inline text across JSX boundaries and list separators; add exactly the whitespace required between adjacent words.
Exceptions / Tradeoffs (EN)
Do not add spaces around punctuation or in languages whose typography does not use them; avoid duplicate literal and expression spaces.