QUESTION: WebStorm -- Inspect Code (Why is wrong attribute value flagged?)

When I choose "CODE -> INSPECT CODE…", a wrong attribute value is reported. Here's what I see:

wrong-attribute-value.png

When I lookup permitted values for the role attribute, I find that navigation is listed as a valid attribute value:

W3C-role-attribute-values.png

QUESTION:

  1. Why is navigation flagged as the wrong attribute value for the role attribute, when W3C lists navigation as a valid attribute value?
  2. What am I missing?

1 comment
Comment actions Permalink

Hi there,

IDE is correct here -- only "banner" (which is a default) and "presentation" are allowed for <header> tag.

http://www.w3.org/html/wg/drafts/html/master/semantics.html#the-header-element

P.S.
Try setting that role on another tag, e.g. <div> -- it will be just fine there (div can have any role).

0

Please sign in to leave a comment.