Garrick Cheung

Sharing what I know and learn about CSS, MooTools, Javascript, PHP and etc.

Aaron Newton brings back $E for MooTools 1.2.1

Posted on | October 29, 2008 | 2 Comments

In Aaron Newton’s announcement of his beta plugins, he’s brought the $E function back, and then some. $E, a function for returning the first element from a selector in MooTools 1.*, was removed from the beta and final release of MooTools 1.2.1.

I thought it was a useful function that was short and sweet.

1
2
3
4
5
//MooTools 1.2.1
$(document.body).getElement('a');
 
//MooTools 1.*
$E('a');

Some of the other plugins Aaron’s released along with $E:

Today I released 9 scripts:

* DollarE – Brings back $E from MooTools 1.11. Returns a single Element for a selector.
* DollarG – Returns a collection when given an element, a collection of elements, an element id, or a selector.
* Hash.Run – Executes every method in a hash. Used for page init function groups.
* HoverGroup – Manages mousing in and out of multiple objects (think drop-down menus).
* InputFocus – Adds a ‘focused’ class to inputs when they have focus.
* MenuSlider – A simple dropdown class; see the menu at the top of Clientcide.com.
* Occlude – Mixin class for preventing a class from applying itself to the same element twice.
* String.FindAllEmails – Finds all the email addresses in a string.
* ToElement – Mixin class that returns *this.element*. Allows you to do $(myInstance).

Way to go Mr. Newton, way to go!

Comments

2 Responses to “Aaron Newton brings back $E for MooTools 1.2.1”

  1. Mike
    October 29th, 2008 @ 3:55 pm

    Hey, checking out your website for the first time. Good stuff.

    Fun fact:

    mootools $E(‘a’);
    jQuery $(‘a:first’);

  2. Garrick
    October 30th, 2008 @ 10:31 am

    @Mike: Thanks! That IS an interesting fact.

Leave a Reply





taking viagra woman Cheap Viagra
cheap gerneric viagra?