+ 1

what is "prototype"? javascript

25th Dec 2016, 12:15 AM
‫אריאל וויס‬‎
‫אריאל וויס‬‎ - avatar
3 Answers
+ 4
"Every JavaScript object has a prototype..." http://www.w3schools.com/js/js_object_prototypes.asp But it's also a JS framework: http://prototypejs.org
25th Dec 2016, 12:24 AM
visph
visph - avatar
+ 4
all objects have many properties and methods. one of the property is prototype but prototype is not an ordinary property it's actually another object that contains default properties that an object inherits. it gets it from other class. in js you can change add or remove properties from prototype. that is the __prototype__ object these are only used in complex program of oop
25th Dec 2016, 5:53 AM
Sandeep Chatterjee
+ 1
thanks
25th Dec 2016, 11:04 AM
‫אריאל וויס‬‎
‫אריאל וויס‬‎ - avatar