SiteLint

  1. Home
  2. Docs
  3. SiteLint
  4. Accessibility Rules
  5. horizontal-rule

horizontal-rule

Print this article

Description

This rule determines <hr/> elements and gives a tip.

Context

The <hr/> element adds extra noise and can be confusing. For example VoiceOver reads it as dimmed collapsed on top, horizontal separator, Windows Narrator reads it as end of line.

A better option is to replace <hr/> with <div> and use CSS for styling. Alternatively, aria-hidden="true" or role="presentation" can be applied to the <hr/> element.

The rule passes when there are:

  1. no <hr/> elements or
  2. <hr/> use aria-hidden="true" or role="presentation"

Standard

Accessibility, Best Practices

Was this article helpful to you? Yes No
SiteLint Audits: Monitoring in real-time Accessibility, Performance, Privacy, Security, SEO, Runtime Errors and Console Logs