Welcome to the first of what I hope will be a regular series of JavaScript tips. Object detection is common in JavaScript. Browser irregularities mean that your code must sometimes contain branches for different browsers. Here is a simple way to speed up object detection for a leaner and meaner script. Instead of this: function addEvent(element, type, handler) { if (element.addEventListener) { ele