best practice - Broken Links Archive

Best Practice for Creating Custom Elements

It looks like custom elements, and web components in general, are beginning to break through into general developer consciousness, as I see more and more articles and talks discussing what they are, what they are good for, and how to make them.

As they’re not yet being used heavily in development, however, I think there’s a good opportunity to define best practices in the way we use them. In this post I want to propose a best practice method for writing custom elements: I’ll do that by comparing two methods for creating custom elements, along with the advantages and drawbacks of each.

Aside: it strikes me that I haven’t written about custom elements here on my own blog, despite having given a few talks and written a few published articles on the subject. In case you’re not sure what they are, I recommend you read my Detailed Introduction To Custom Elements first.

Read the full article

Bad advice: people still teaching CSS hacks

There’s so much great stuff written about web standards available for free on the web that it’s easy to forget how much bad stuff is also out there; and how many people are willing to support it just because it’s easier than putting in a little extra effort to follow best practice.

Over the weekend one of the most popular stories on was teaching the use of lazy CSS hacks, the type of which I thought everybody was convinced enough to do away with; the star and underscore hacks for targeting IE6 & IE7, the hacks which we’ve been saying (for years) shouldn’t be used anymore.

Disregarding the ‘rights’ and ‘wrongs’, and the validation argument — some of my stylesheets don’t validate, and there are good reasons for that — I’d like to give a few other reasons why using this method is not a good idea.

Read the full article

A website unfit for a queen

To great fanfare, The Queen, in the company of Sir Tim Berners-Lee, unveiled the new British Monarchy website today. Unfortunately, what they unveiled was a real dog’s dinner. highlights the worst elements of the practice of web development; on only the second page I visited it became obvious that the site hasn’t been tested on any browser other than Internet Explorer, and a peek at the source code left me shocked.

Read the full article

Web standards and the environment

A calendarial mishap left me thinking that Blog Action Day was on the 18th October when in fact it is, of course, today. It’s 23.00 here as I write this, so I have one hour to write a post and officially get away with it.

So the title of the post is “web standards and the environment”, which at first seems pretty incongruous. To be honest, at second and third it still seems pretty incongruous. But I want to make the case that concerning yourself with the environment is like concerning yourself with web standards.

Read the full article


I’ve updated my Speaking page to include more conferences, more videos, and a little on my speaking requirements and preferences. I’m planning to cut down on the number of talks I give in 2014 (twelve is too many), but am always open to interesting offers and opportunities, so please get in touch if you’re organising an event.

[#] 1 Comment . More Asides.