Tuesday, September 25th, 2007
Category: JavaScript
, Library
, Prototype
<
>p
>James Coglan has ported ideas from ideas from Ruby's Symbol#to_proc and
Methodphitamine to create
Reiterate, a library for Prototype.
The library means that instead of code like this:
JAVASCRIPT:
-
-
var value = radioGroup.find(function(radio) {
-
return radio.checked;
-
}).value;
-
-
var divs = someDivs.findAll(function(div) {
-
return div.hasClassName('myClass') && div.visible();
-
});
-
you can write:
JAVASCRIPT:
-
-
var value = radioGroup.find('checked').value;
-
-
var divs = someDivs.findAll({hasClassName: 'myClass', visible: true});
-
Download Reiterate.
- Ajax seen solving JavaScript issues for RIA
For rich Internet application (RIA) development, Ajax is doing for JavaScript what JavaScript couldn't do alone, the author argues. "The browser wars...
- FAQ: Lotus Notes, Domino and JavaScript
Caught in a JavaScript jam? Before posing a question to our SearchDomino.com experts, check out our list of frequently asked questions on JavaScript...
- Junk JavaScript?
Should JavaScript and HTML be replaced with "proper" languages that might give more bang for the buck in rich Internet applications (RIAs)? One reader...
- JavaScript Learning Guide
This SearchDomino.com guide introduces you to JavaScript in a Notes/Domino environment, explains best practices and pitfalls to avoid and provides...
- JavaScript Library in a Notes database
Do you need the same JavaScript code in many Notes forms? This tip will shows you how you can maintain JavaScript code in only one...
Enumerable on steroids! This syntax is truly amazing…
Looks like the first steps in making prototype operate like jquery.
forget jqueery.
have you guys tried moo?
sorry, couldn’t resist.
@Glen, you must mean more like ruby. This has nothing todo with another framework, ktnxbye
@Steve: how can I go to my boss and tell him we should try a library called ‘Moo Tools’? You guys need a better name to be taken seriously.
@Les, i was just kidding about the moo comment. i think the framework wars are pretty silly (as is the name “moo”)
@Glen: indeed, I had some strange déja vu feeling ;-)
@Steve and @Frank: mootools = my object oriented tools, if your boss makes his decisions based on how cool of a name something has, then I suggest you find a new job … since the company won’t be around for much long.
Woopsie … I need more sleep … above comment for Steve and Les … sorry Frank … blah! Ajaxian needs a better comment system, like the one on Engadget, where you can reply to comments.
jquery
@Marat
Considering that Ruby on Rails is usually used based on the name or hype rather than an actual business case, maybe judging by a name isn’t so bad. ;-)
Plus, mootools sounds pretty cool.
You could just call it “moot-ools”. Now that is just Moot ools of fun… :)
Thanks for that
ha ha