TECHSITH = Technology Simple Intuitive Tutorial Home

Object.create

prototype

Object.setPrototypeOf() Method JavaScript

There are two camps in JavaScript, one who uses function constructors to create objects and one who directly uses object literals. In JavaScript, function constructors can be extended by using the Object.create() method. This method lets you set prototype of one object to another object. Constructor2.prototype = Object.create(Constructor1.prototype); Extending Object Literals Object literals don’t have …

Object.setPrototypeOf() Method JavaScript Read More »

javaScript function constructors

JavaScript Function Constructors

It is very important to understand how JavaScript function constructors work before we move to higher level topics of Object Oriented JavaScript. In this article, I am not going to explain about the JavaScript class constructor. Instead, I’ll explain about ‘function’ constructors. The ultimate objective of Object Orient Programming is to create objects with ease. …

JavaScript Function Constructors Read More »

Scroll to Top