0

What is a prototype function in Javascript

Javascript

30th May 2021, 2:40 PM
Edward Jackson Jr
Edward Jackson Jr - avatar
3 ответов
+ 4
Te refieres a este tipo de funciones? https://code.sololearn.com/cMnrTm5QGZZ1/?ref=app
30th May 2021, 2:46 PM
Cmurio
Cmurio - avatar
+ 1
JS is an Object Oriented Programming language... roughly, there is two kind of implementing OOP: by classes, and by prototyping. most of OOP languages uses classes, while JS use prototype... even in latest version where it has introduced the syntactic sugar of 'classes' (internally, that's still implemented using prototyping ;P consider that both class and prototype based OOP define a blueprint used to build objects of same kind/family... A good source reference to dive into the prototype specificities mechanic used in JS is the mdn site: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Details_of_the_Object_Model https://developer.mozilla.org/en-US/docs/Learn/JavaScript/Objects/Object_prototypes https://developer.mozilla.org/en-US/docs/Web/JavaScript/Inheritance_and_the_prototype_chain
30th May 2021, 6:19 PM
visph
visph - avatar