Mathias Bynens 5/4/2010

The HTML5 `document.head` DOM tree accessor

Read Original

This technical article details the HTML5 `document.head` DOM accessor, a convenient and efficient alternative to `document.getElementsByTagName('head')[0]`. It covers native support detection, provides a simple polyfill for older browsers, and discusses edge cases and community feedback on implementation nuances and JSLint compatibility.

The HTML5 `document.head` DOM tree accessor

Comments

No comments yet

Be the first to share your thoughts!

Browser Extension

Get instant access to AllDevBlogs from your browser

Top of the Week

No top articles yet