The language itself is NOT object-orientated, its proto-type based. It can be used in an OOP fashion, but this is not true Object Orientation as it is in languages such as C++.
On Fri, Oct 24, 2008 at 1:16 PM, <[EMAIL PROTECTED]> wrote: > > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > On Behalf Of Brett Patterson > > Sent: 24 October 2008 02:25 > > To: [email protected] > > Subject: Re: [WSG] JavaScript clarification please > > > > > > Oh, most definitely agreed. Sorry if I started an argument, I only > wanted to know > > what it was. I don't know if it is just me, but this topic seems to be > too > > controversial. Thank you all for answering. > > > > Actually, I think you have stumbled upon one of the keys to this issue: > it is controversial amongst people who are not familiar with the > language. Most of the confusion comes from people who are experts in PHP > or C++, and who believe that makes them expert in OO, or indeed > University Lecturers that are proficient in neither. > > If you ask people who are truly expert with JavaScript, they will all > tell you that it _is_ Object-Oriented, not least because it is entirely > object-based: the first rule of JavaScript is: "Everything is an object. > A function is an object, a string is an object, and an array is an > object." > > As others have said, most other OO languages implement class-based > inheritance, often as a result of their linear underpinnings. People who > are used to this approach, then go through some horrible kludges to > simulate this unnecessarily in JavaScript apps, and then complain that > the results are horrible. Prototype-based inheritance is a very > different beast, and one that is much better suited to the way that > JavaScript is supposed to be used. > > Final point of confusion: the library called 'Prototype'. Stupid name - > never used a languages reserved word for anything: it is reserved for a > good reason, but is now better known than object.prototype itself! > > > Regards, > Mike > > > Mike Brockington > Web Development Specialist > > www.calcResult.com <http://www.calcresult.com/> > www.stephanieBlakey.me.uk <http://www.stephanieblakey.me.uk/> > www.edinburgh.gov.uk > > This message does not reflect the opinions of any entity other than the > author alone. > > > ******************************************************************* > List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm > Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm > Help: [EMAIL PROTECTED] > ******************************************************************* > > ******************************************************************* List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *******************************************************************
