Simon Willison’s Weblog

Items tagged dom

Filters: dom ×


Unimpressed by NodeIterator. John Resig, one of the most talented API designers I’ve ever come across, posts some well earned criticism of the document.createNodeIterator DOM traversal API. # 19th June 2009, 9:53 pm

Crowbar. Headless Gecko/XULRunner which exposes a web service API for screen scraping using a real browser DOM—just pass it the URL of a page and the URL of a screen scraping JavaScript script (a bit like a Greasemonkey user script) and get back RDF/XML. # 24th January 2009, 11:52 pm

Visual Event. External code loading bookmarklet that visualises the JavaScript events hooked up to the current page, and lets you view the source code of the event handling function for each one. Only works for events added by jQuery, YUI or MooTools since those libraries maintain a cache of event handlers that they add, to work around the standard DOM’s omission of handler introspection. # 10th December 2008, 3:38 pm

Implementing a syntax-higlighting JavaScript editor in JavaScript. Appropriately subtitled “a brutal odyssey to the dark side of the DOM tree”. Some seriously clever trickery going on here. # 4th April 2008, 8:27 am

<META HTTP-EQUIV=“X-BALL-CHAIN”>. Mozilla hacker Robert O’Callahan discusses the technical implications of freezing copies of older rendering engines, including the increased footprint and the terrifying prospect of documents in different rendering modes communicating through iframes and the DOM. # 22nd January 2008, 6:55 pm

jQuery 1.2.2: 2nd Birthday Present. The API stays the same, but there are some healthy speed improvements, a new way of adding custom events and (most importantly) .ready() now waits for the CSS to be ready in addition to the DOM. # 15th January 2008, 8:59 am

In the long term, I want to replace JavaScript and the DOM with a smarter, safer design. In the medium term, I want to use something like Google Gears to give us vats with which we can have safe mashups. But in the short term, I recommend that you be using Firefox with No Script. Until we get things right, it seems to be the best we can do.

Douglas Crockford # 7th November 2007, 3:36 pm

Live Query jQuery plugin. Ingenious plugin that lets you register jQuery event bindings to be executed when a new element matching the provided selector is added to the DOM. Performance is kept snappy by only running the check after a jQuery DOM manipulation method has been executed (append, prepend, attr etc); it won’t notice elements added using regular DOM methods. # 22nd August 2007, 10:01 pm

Atom Models. Building Python classes that act as utility wrappers around data stored in an lxml DOM object. # 7th August 2007, 4:02 pm

Mouseover DOM Inspector v2.0. Steve Chipman’s excellent debugging bookmarklet created back in 2005—includes useful keyboard shortcuts for quickly manipulating the DOM of the current page. # 30th July 2007, 5:13 pm

Low Pro Behaviours 101. A neatly packaged method of enhancing an existing DOM element with pre-packaged behaviours. # 17th July 2007, 10:09 am

Live DOM Viewer (via) Neat tool from Hixie that provides an insight in to what browsers are actually thinking. # 6th February 2007, 1:12 am