W3C home > Mailing lists > Public > whatwg@whatwg.org > March 2015

Re: [whatwg] Thoughts on the <nav> element

From: Andrea Rendine <master.skywalker.88@gmail.com>
Date: Tue, 24 Mar 2015 16:08:25 +0100
Message-ID: <CAGxST9=rhPYQBD6ydPLfWoSaNiYVbDFmB7Kc_PJEY_Tn2-kcyA@mail.gmail.com>
To: WHATWG List <whatwg@whatwg.org>
At first sight I wouldn't define this case so "impractical" or "senseless".
Looking at your example it looks like that the <nav> element is related
with the site itself (e.g. other articles, other sections of the site), not
with the page. If you had a heading element for the whole site (e.g. the
site name), you'd set it above the <nav> itself.
I don't know your language standards, but IMHO the title of the main
article of the page is not strictly meant to define the title for the page
itself, luckily there's the <title> element in <head> to do that.

2015-03-24 15:49 GMT+01:00 Reinier Kaper <rp.kaper@gmail.com>:

> Hey guys,
>
> I've been worrying (maybe too much) about the <nav> element lately.
> In my experience, it has become more of a burden than a help when it comes
> to the document outline.
>
> The <nav> element forces a new outline section, therefore requiring a
> heading and (implicitly) requiring a heading to precede the <nav> element
> as its parent.
>
> Main navigation tends to be at the (physical) top of the document, forcing
> a heading to precede it is not only impractical, but also irrelevant.
>
> Let me demonstrate with a practical example:
>
> <body>
>
>  <header>
>   <nav>
>    <h2>Navigation></h2>
>    <ul>...</ul>
>   </nav>
>  </header>
>
>  <main>
>   <h1>Page/article title</h1>
>   <p>...</p>
>  </main>
>
>  <footer>...</footer>
> </body>
>
> This will break the outline, as the nav element (regardless of the heading
> used) will create a new part of the outline and "missing" a preceding
> heading.
>
> Unless you have a fixed position navigation/header this will not fly from a
> styling perspective and simply makes no sense. It's completely normal to
> start with the header of a site/page, including the (global) nav, instead
> of the site/page title.
>
> I would like to see a discussion as to making the nav not sectioning
> content, but behave more like other semantical elements that don't force
> part of the outline.
>
> If more examples are required I can create a small Gist or something.
>
> Thoughts?
>
> Kind regards,
> Reinier Kaper.
>
Received on Tuesday, 24 March 2015 15:09:21 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:29 UTC