what is the point of using super in javascript code example
Example 1: javascript super
class Parent {
constructor() {}
method() {}
}
class Child extends Parent {
constructor() {
super() // Parent.constructor
super.method() // Parent.method
}
}
Example 2: Super in javascript
super([arguments]); // calls the parent constructor.
super.functionOnParent([arguments]);