It’s not that HTML is impossible to read or write — it’s just awkward.
For starters there’s the pinky finger problem. You know — the keyboard sequence for creating a tag: the left pinky finger holds down the Shift key while the right middle finger searches for the < key . . . then you release the Shift key while typing the tag's mnemonic characters . . . then once again with the left pinky Shift key thingy, while the right ring finger (or is it the one next to it?) fumbles around for the > key.
Then — after composing the paragraph or phrase or word — the whole process is repeated with the closing tag, with all the same keystrokes plus the ergonomic coup de grâce: the right pinky hitting the / key while remembering that the left pinky should momentarily let up on pressing the Shift key!
Try doing this for a sustained period and you’ll soon be filing a worker’s compensation claim for ergonomic injury. It’s like the party game Twister, where your body parts get tied in knots just by following the rules.
So writing HTML is unpleasant, but what about reading it?
In actual practice, HTML tags seldom appear stand-alone. Attributes are frequently applied to tags in order to associate them with styling rules (CSS). And on dynamic documents, attributes are applied to tags for dynamic manipulation (JavaScript). Both of these clutter the document significantly.
But the real problem is that tags and attributes aren’t just lightly sprinkled here and there; they’re dumped all over the document in a downpour — like one of those climate change rainfalls that floods the city so you can’t see the streets anymore.
Reading an HTML document — even one that has color syntax highlighting — makes you wish there was a legal signal-to-noise limit, with offenders getting fined. It’s not uncommon to discover documents where the noise is so many times greater than the signal that it’s impossible to find the author’s words.
If Clara Peller was still around, she’d be demanding to know “Where’s the content?”
HTML wasn’t supposed to be like this.
Excerpted from Variations on the HTML Two-Step.
Top comments (0)