When I first heard that Hixie had removed all traces of the
time element from the ongoing HTML spec, my knee-jerk reaction was “This is a really bad idea!” But I decided not to jump in without first evaluating the arguments for and against the element’s removal. That’s what I’ve been doing over the past week and my considered response is:
This is a really bad idea!
The process by which the element was removed is quite disturbing:
- Hixie (as a contributer) opens a bug proposing that the
timeelement be replaced with the more general
- Lots of people respond, almost unanimously pointing out the problems with that proposal.
- Hixie (as the editor) goes ahead and does what exactly what he wanted anyway.
Technically that’s exactly how the WHATWG process works. The editor does whatever he wants:
This is not a consensus-based approach — there’s no guarantee that everyone will be happy! There is also no voting.
Most of the time, this works pretty well. It might not be fair but it seems to work more efficiently than the W3C’s consensus-based approach. But in this case the editor’s unilateral decision is fundamentally at odds with the most important HTML design principle, the priority of constituencies:
In case of conflict, consider users over authors over implementors over specifiers over theoretical purity. In other words costs or difficulties to the user should be given more weight than costs to authors; which in turn should be given more weight than costs to implementors; which should be given more weight than costs to authors of the spec itself, which should be given more weight than those proposing changes for theoretical reasons alone.
The specifier (Hixie) is riding roughshod over the concerns of authors.
I’m particularly concerned by the uncharacteristically muddy thinking behind Hixie’s decision. There are two separate issues here:
- Is the
- Do we need a more general
Hixie conflates these two questions.
He begins by bizarrely making the claim that
time hasn’t had much uptake. This is demonstrably false. It’s already shipping in Drupal builds and Wordpress templates as well as having parser support in services and at least one browser. If anything,
time is one of the more commonly used and understood elements in HTML5.
There’s a very good reason for that: it fulfils a need that authors have had for a long time—the ability to make a timestamp that is human and machine-readable at the same time. That’s the use case that the microformats community has been trying to solve with the abbr design pattern and the value-class pattern. Those solutions are okay, but not nearly as elegant and intuitive as having a dedicated
time element didn’t just specify the mechanism for encoding a machine-readable timestamp, it also defined the format, namely a subset of ISO 8601. That’s exactly the kind of unambiguous documentation that makes a specification useful.
Hixie correctly points out that there are cases for human and machine-readable data other than dates and times. He incorrectly jumps to the conclusion that the
time is therefore a failure.
I think he’s right that there probably should be a dedicated element for marking up this kind of data. We already have the
meta element but the fact that it’s a standalone element makes it tricky to explicitly associate the human-readable text. So the introduction of a new
data may very well turn out to be a good idea. But it does not need to be introduced at the expense of the more specific
I think there’s a comparison to be made with sectioning content. We’ve got the generic
section element but then we also have the more specific
article elements that can be thought of specialised forms of
section. By Hixie’s logic, there’s no reason to have
article when a
section element has the same effect on the outlining algorithm. But we have those elements because they cover very common use cases.
Hixie’s reductio ad absurdum argument is that if there is a special element for timestamps, we should also have an element for every other possible piece of machine-readable data. If that’s the case we should also have an infinite amount of sectioning content elements:
chapter, etc. Instead we have just the four elements—
nav—because they represent the most common use cases …perhaps 80%?
The use case that the
time element satisfies (human and machine-readable timestamps) is very, very common. The actual mechanism may vary (the
time element itself, the
abbr pattern, etc.) but the cow path is very much in need of paving.
There’s also a disturbingly Boolean trait to Hixie’s logic. He lumps all machine-readable data into the same bucket. If he had paid attention to Tantek’s research on abstracting microformat vocabularies, he would have seen that it’s a bit more fine-grained than that. There’s a difference between straightforward name/value pairs (like
summary), URL values (like
photo) and timestamps (like
dtstart). The thing that distinguishes timestamps is that they have an existing predefined machine-readable format.
To strengthen his position Hixie introduced two strawmen into the discussion, claiming that the
time element was intended to allow easier styling of dates and times with CSS and to also allow conversion of HTML documents into Atom. Those use cases are completely tangential to the fundamental reason for the existence of the
time element. Hixie seems to have forgotten that he himself once had it enshrined in the spec that the purpose of the element was to allow users to add events to their calendars. I pointed out that this was an example usage of the more general pattern of machine-readable dates and times so the text of the spec was updated accordingly:
This element is intended as a way to encode modern dates and times in a machine-readable way so that, for example, user agents can offer to add birthday reminders or scheduled events to the user’s calendar.
No mention of styling. No mention of converting documents to Atom.
I’m not the only one who is perplexed by Hixie’s bullheaded behaviour. Steve Faulkner has entered a revert request on the W3C side of things (he’s a braver man than me: the byzantine W3C process scares me off). Ben summed up the situation nicely on Twitter. You can find plenty of other reactions on Twitter by searching for the hashtag #occupyhtml5. Bruce has written down his thoughts and the follow-on comments are worth reading. This reaction from Stephanie is both heartbreaking and completely understandable:
I have been pretty frustrated by this change. In fact, when I read the entire thread on the debacle, it nearly made me want to give up on teaching, and using HTML5. What’s the point when there’s really no discussion? A single person brings something up. Great arguments are made. And then he just does what he originally wanted to do anyway.
I’d like to think that a concerted campaign could sway Hixie but I don’t hold out much hope. Usually there’s only one way to get through to him and that’s by presenting data. Rightly so. In this case however, Hixie is ignoring the data completely. He’s also wilfully violating the fundamental design principles behind HTML5.
So what can we do? Well, just as with the incorrectly-defined semantics of the
cite element we can make a stand and simply carry on using the
time element in our web pages. If we do, then we’ll see more parsers and browsers implementing support for the
time element. The fact that our documentation has been ripped away makes this trickier but it’s such a demonstrably useful addition to HTML that we cannot afford to throw it away based on the faulty logic of one person.
Hixie once said:
The reality is that the browser vendors have the ultimate veto on everything in the spec, since if they don’t implement it, the spec is nothing but a work of fiction. So they have a lot of influence—I don’t want to be writing fiction, I want to be writing a spec that documents the actual behaviour of browsers.
Keep using the