Re: HTML5 and XHTML2 combined (a new approach)

On Thu, 22 Jan 2009, Giovanni Campagna wrote:
> 2009/1/22 Ian Hickson <ian@hixie.ch>
> > On Thu, 22 Jan 2009, Giovanni Campagna wrote:
> > >
> > > Actually, only http://dev.w3.org/html5/spec/ can be considered HTML5 
> > > (a vocabulary and associated api for (X)HTML): the other are not 
> > > dependent or related to HTML (the markup language), although 
> > > implemented together, and are in scope of Web Applications WG (and 
> > > are developed there).
> >
> > Well by that definition, any spec is "monolithic", then, so Mark's 
> > slur is meaningless.
> 
> No: there are "monolithic" specs, that try to define everything "from 
> producer to consumer", and spec that address very specific use case and 
> technologies. HTML5 is "monolithic" in that sense, behavior in the 
> middle of web page processing, generation, etc. is very difficult to 
> modify. XHTML2 is "modularized": a collection of "specific" specs (each 
> XHTML module could be considered an independent specification, besides 
> of W3C Process Document) that integrate together.

If by this you mean that the XHTML2 specification doesn't define 
processing rules for its language, then I agree. But that's a bug, not a 
feature. We need detailed conformance requirements so that we can have 
uniformity of implementations.

You could consider each HTML5 chapter or section to be its own independent 
specification, if you like. Indeed the WebSocket API spec and the 
WebSocket protocol spec are both generated from the HTML5 document's 
source file, so they literally are sections of HTML5.


> > > Even the fact that you consider WebWorkers or XMLHttpRequest (or 
> > > even the WebSocket protocol) as part of HTML5 is against modularity 
> > > and extensibility: they're independent technologies with different 
> > > use cases, conformance requirements and designs. Why shouldn't I be 
> > > able to use WebSocket from a C++ application? Or use XMLHttpRequest 
> > > with image/png (XHR2 of course)? Or implemnt Selectors API in a 
> > > Gnome's LibXML2?
> >
> > You can use HTML5 from a C++ application (most Web browsers do!). And 
> > the HTML5 APIs and features (e.g. <iframe>) can be used with 
> > image/png. And you could implement HTML5's getElementsByClassName() 
> > feature in libxml2 just like the Selectors API.
> 
> You (I hope not willfully) ignored my point: can I use what you called 
> "HTML5 related" technologies without implementing HTML5?

I don't know what you mean by "HTML5" in that sentence. The Web platform 
as a whole -- from the text/html serialisation to the Window object to the 
XHR constructor to the value of the Origin header and everything in 
between and around it -- are all interrelated in various ways, sometimes 
closely, sometimes loosely. There are parts of the HTML5 spc that don't 
depend on other parts of the HTML5 spec, and there are parts of Web 
Workers that depend on parts of the HTML5 spec. The whole caboodle is 
designed is designed from the ground up to be implementable piecemeal, 
because that's how the Web grew.


> Can I use WebSockets using carefully crafted byte streams and POSIX 
> sockets api? Can I use XMLHttpRequest to fetch an image/png (or any 
> other type of data), ignoring the Content-Type sniffing (because both 
> Apache and IIS automatically append a Content-Type for static content, 
> even if just application/octet-stream), the text/html parsing, the 
> responseXML implementing HTMLDocument interface, etc.? Can I put a 
> method called "querySelectorsAll", that processes a CSS Selectors and 
> fetches a DOM NodeList inside LibXML2, in an application that has 
> nothing to do with HTML (or web in general), but happens to like 
> Selectors more than XPath? Yes, of course I can. This is modularization.

If that's modularisation, then HTML5 is modular! You can use MessagePorts
without having a Window, you can use addEventSource() in SVG, you can use 
the text/html parsing without having a SQL database, you can put a method 
called getElementsByClassName() in libxml2...

I doubt that's what Mark meant, though maybe he could clarify.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Thursday, 22 January 2009 21:19:38 UTC