constructorExtends
{Boolean}
Toggles the behavior of a constructor function called
without the new
keyword to extend the constructor function or
create a new instance.
var animal = Animal();
// vs
var animal = new Animal();
{Boolean}
Toggles the behavior of a constructor function called
without the new
keyword to extend the constructor function or
create a new instance.
var animal = Animal();
// vs
var animal = new Animal();
If
constructorExtends
is:true
- the constructor extendsfalse
- a new instance of the constructor is createdThis property defaults to false.
Example of constructExtends is true:
The default behavior is shown in the example below:
By default to extend a constructor, you must use extend.