Re: Google's HTML5 Stylesheet

> http://google-styleguide.googlecode.com/svn/trunk/htmlcssguide.xml#Protocol
>
> "Do not use type attributes for style sheets (unless not using CSS) and
> scripts (unless not using JavaScript)."
>
> Whereas the W3C validator is giving a warning (see image).

What DOCTYPE does your test document use?

The guideline has to be seen in the context of HTML 5:
<http://google-styleguide.googlecode.com/svn/trunk/htmlcssguide.xml?showone=Document_type#Document_type>.

See e.g. how HTML 5 handles @type on <link> [1], <style> [2], and
<script> [3] elements.


[1] http://www.whatwg.org/specs/web-apps/current-work/multipage/semantics.html#attr-link-type
[2] http://www.whatwg.org/specs/web-apps/current-work/multipage/semantics.html#attr-style-type
[3] http://www.whatwg.org/specs/web-apps/current-work/multipage/scripting-1.html#attr-script-type

--
Jens O. Meiert
http://meiert.com/en/

Received on Thursday, 10 May 2012 04:25:55 UTC