Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How do I do OO programming in Javascript?

Javascript OO Programming
0
Posted

How do I do OO programming in Javascript?

0

Object Oriented functionality (if you can call it that) in Javascript is radically different. A prototype-based language, such as JavaScript […] simply has objects. A prototype-based language has the notion of a prototypical object, an object used as a template from which to get the initial properties for a new object. Any object can specify its own properties, either when you create it or at run time. In addition, any object can be associated as the prototype for another object, allowing the second object to share the first object’s properties. [Core JavaScript 1.5 Guide:Details of the Object Model] So, there are no class objects in javascript, just function objects. The latter will be referred to as constructor function objects (CFO) throughout this document.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.