Fun With Mootools Part 1: The Class toElement method

2012 Apr15

T

he MooTools ( My Object Orientated Tools ) JavaScript framework is a pretty sweet piece of software. It's goal is to make developing with JavaScript easier. It provides large set of tools for building complex JavaScript applications. There are a lot of hidden goodies tucked away in the framework that kick off one of those "AHa!" moments. One of those goodies is the toElement method on classes. One of those goodies is the toElement method on classes.

The Class' method, toElement, works in tandem with the MooTools document.id ( $ ) method. In most cases, Classes center around a DOM element for some reason or another. As a convenience, the document.id ( $ ) will call the toElement method when it is passed

Read More
filed under:  dom mootools class javascript oop