|
|
|
|
|
by chuckadams
656 days ago
|
|
It looks like <header> is treated specially when it’s directly under the <body> tag, but generic everywhere else. This is actually what I want for some widgets which may be arbitrarily nested and aren’t really contributing to a hierarchy, but not others where I would want to be able to navigate between the sections using the headings. I like the idea of just using <h2> for all depths below the very top, I think I’ll start doing that for headers that should be navigation targets. Edit: looks like that’s basically the WAI approach too, in that role=heading will default to aria-depth=2. |
|
Using <header> elsewhere for developer convenience is fine but that's all it is.
Headings are especially helpful for screen reader users are especially helpful but their value for sighted users are often underestimated. Developers think that by putting something in a box and by its styling that people will understand what it is, what it's for, when using a heading to put a name on it would be very clarifying.