JavaScript Objects The Number Object- Prototype - Javascript Objects

What is JavaScript Object - prototype?

The prototype property is used to add properties and methods to any object (Number, Boolean, String and Date etc.).

Note − Prototype is a global property which is available with almost all the objects.


The syntax to use Prototype is as follows.


The following example tells how to use the prototype property to add a property to an object.


JavaScript Number Object Prototype Output

All rights reserved © 2020 Wisdom IT Services India Pvt. Ltd Protection Status

Javascript Objects Topics