Rules
- •
Semantic Tags: Use
<main>,<nav>,<header>,<footer>,<section>,<article>. Avoid<div>for structural elements. - •
Headings: Ensure a logical heading hierarchy (H1 -> H2 -> H3).
- •
Alt Text: All images must have descriptive
altattributes or emptyaltfor decorative images. - •
Smart Links: Detect and wrap actionable text patterns in appropriate links:
- •Phone numbers ->
<a href="tel:+1234567890">...</a> - •Emails ->
<a href="mailto:example@com">...</a> - •Physical addresses ->
<a href="https://maps.google.com/?q=...">...</a>(optional, based on context)
- •Phone numbers ->
- •
Modern Link Security:
- •Reverse Tabnabbing: For
target="_blank", ALWAYS userel="noopener". - •XSS Prevention: Never use
javascript:pseudo-protocol inhref. - •Referrer Leakage: Use
referrerpolicyattribute (e.g.,no-referrerorstrict-origin-when-cross-origin) instead of relying solely onrel="noreferrer".
- •Reverse Tabnabbing: For