>As far as the current validator behavior goes, the underlying problem is
>that the HTML parser used by the validator doesn't yet treat <menuitem> as
>void. We need to first change the parser to treat it as such.
Wait, it's not only a problem with the Validator parser. User agents parse
subsequent <menuitem>s as nested in previous ones. I know that the model is
that and it's correct without the end tag but what are authors supposed to
do in order to serve <menu>s to legacy UAs maybe with a bit of a JS
polyfill in the future?
2014-02-12 18:00 GMT+01:00 Michael[tm] Smith <mike@w3.org>:
> David Dorward <david@dorward.me.uk>, 2014-02-10 21:57 +0000:
>
> > On 10 Feb 2014, at 21:34, Andry Rendy wrote:
> >
> > >>Where does it say that you may omit the end tag?
>
> The end tag for <menuitem> actually must be omitted. It's now defined as a
> void element, so it's a parse error for it to have an end tag.
>
> > >The original WHATWG draft mentions it.
> > >
> http://www.whatwg.org/specs/web-apps/current-work/multipage/interactive-elements.html#the-menuitem-element
> >
> > I suspect Nu is keyed off the W3C specification, not the WHATWG one.
>
> The W3C spec also says that <menuitem> is void -
>
> http://www.w3.org/html/wg/drafts/html/master/syntax.html#void-elements
>
> As far as the current validator behavior goes, the underlying problem is
> that the HTML parser used by the validator doesn't yet treat <menuitem> as
> void. We need to first change the parser to treat it as such.
>
> --Mike
>
> --
> Michael[tm] Smith http://people.w3.org/mike
>