Prototype inheritance passing arguments to instance properties or methods | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Prototype inheritance passing arguments to instance properties or methods

Can we pass arguments or parameters to a properties and methods of a constructor using prototype inheritance of other constructor? I read in a book they use .call() or .apply() to pass arguments to other constructor. I wonder if we can do it using inheritance?

19th Apr 2017, 9:21 AM
Donny Gozali
Donny Gozali - avatar
0 Answers