Re: [Proto-Scripty] Re: Extending a DOM-Object

2010-11-23 Thread Bertilo Wennergren
On Tue, Nov 23, 2010 at 03:39, JoJo wrote: > Why is the Element::store() not listed in the documentation??? > http://www.prototypejs.org/api/element . Good question. You'll find the current documentation here: http://api.prototypejs.org/dom/Element/store/ > Thanks for pointing out this featu

[Proto-Scripty] Re: Extending a DOM-Object

2010-11-22 Thread JoJo
Why is the Element::store() not listed in the documentation??? http://www.prototypejs.org/api/element . Thanks for pointing out this feature. I've been stupidly creating my own data structures to further describe DOM elements. Now I don't have to do that. On Nov 22, 12:31 pm, Luke wrote: > Thank

[Proto-Scripty] Re: Extending a DOM-Object

2010-11-22 Thread Luke
Thank you Mr Crowder, that was quite informative. Still I'm a little unsure how to proceed. If I got this right, it is common sense now that extending the DOM is the wrong thing to do. One of the main reasons is the possibility of name-conflicts. So I thought I might extend Objects with a JSON-Obj

[Proto-Scripty] Re: Extending a DOM-Object

2010-11-21 Thread T.J. Crowder
Hi Luke, What you're talking about doing is called an "expando" property. They're not covered by a standard AFAIK, although interestingly Microsoft has an `expando` property on objects[1] (this is where the name came from) which is a boolean saying whether you can do this. If you do a web search o

[Proto-Scripty] Re: Extending a DOM-Object

2010-11-21 Thread Luke
Thanks Walter. If that's the only reason I'm willing to take that risk. In my whole application I will only attach one variable, kind of like my namespace and this will give me some convenience when accessing that namespace. If it's conform to W3C standards and works in all browsers, I think it's o