Why are there many ways to implement inheritance? I feel that it is very good to realize inheritance.

I can see that there are many ways to implement inheritance, such as combinatorial inheritance and parasitic inheritance, and some of them have many shortcomings. I feel that either the following or es6 can realize inheritance very well. Why are there any of the above methods

?
function Parent(name) {
  this.name = name
}
Parent.prototype.getName = function() {
  console.log(this.name)
}

function Child(name) {
  Parent.call(this, name)
  this.*** = ***
  ///
}
Child.prototype = Object.create(Parent.prototype)
child.prototype.fn = function***
///
Mar.28,2021

all come step by step with the development of the language.
Class is convenient but not before ES6, Object.create is convenient but not before ES5.


you can't say that your old friends don't want it when you grow up.
these are all problems left over by history.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3f3a6-414ba.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3f3a6-414ba.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?