When a subclass needs to reuse setup or behavior from its parent class, `super` provides access to the superclass constructor and prototype methods. It works alongside class inheritance, which uses the prototype chain. section 28.0 section 28.2
Keep these rules in mind:
- Call `super()` in a subclass constructor before referring to `this`; otherwise, the reference causes a `ReferenceError`. section 28.2
- Use `super.method()` to invoke an overridden method on the superclass prototype. Class properties set on an instance cannot be accessed through `super`. section 28.2 section 28.4
- An arrow-function class property is attached to the instance, not the prototype, so subclasses cannot call it through `super`. To keep a method extendable while binding it, define it as a method and bind it in the constructor. section 28.3
Listing 28.2. Invoking the superclass constructor with super
A subclass can pass its fixed resource to the superclass constructor with `super()`. section 28.2
Listing 28.3. Invoking superclass methods with super
An overridden `fetch` method can add analytics behavior, then delegate to the superclass implementation with `super.fetch(id)`. section 28.2





