I blogged about this issue here:
http://www.samsaffron.com/archive/2008/02/09/A+cleaner+way+to+iterate+through+Enumerable+lists+in+Prototype
I think iterators look nicer when you have the scope as the first
param.
--~--~-~--~~~---~--~~
You received this message
Completely disagree. First of all, you don't need the parentheses in your
first example. You can simply do stuff like function() {...}.bind(this).
Secondly, in your conclusion you are assuming that you will always _need_ to
correct scope, when in fact you only need to do this if you want to use
On Feb 8, 3:34 pm, Ryan Gahl [EMAIL PROTECTED] wrote:
Completely disagree. First of all, you don't need the parentheses in your
first example. You can simply do stuff like function() {...}.bind(this).
Actually if you run
window.hello = ninja;
var MyClass = Class.create ({
test:
On this point I have to say, It is really hard to extend prototype,
there should be a central registry Object.Extend writes to and I
should not have to write 20 lines of code to change the behavior of
each in all enumerables, it should be possible to do this in one line
of code .
I guess,
Keep in mind also... I'm just one vote. I can't tell you how many times I've
been outvoted here :)
--
Ryan Gahl
Manager, Senior Software Engineer
Nth Penguin, LLC
http://www.nthpenguin.com
--
WebWidgetry.com / MashupStudio.com
Future Home of the World's First Complete Web Platform
--
Inquire:
Last I checked, Object.extend doesn't check if a child is defined
before redefining.
So, that shouldn't be too difficult.
Sure, but unless I am missing something .. I have to call
Object.extend on Array.prototype, Hash.prototype, ObjectRange,
Ajax.Responders, Element.ClassNames.prototype to