easierbycode
4/29/2016 - 6:12 PM

calling super.methodName from subclass

calling super.methodName from subclass

class Project {
  getTaskCount() {
    return 50;
  }
}

class SoftwareProject extends Project {
  getTaskCount() {
    return super.getTaskCount() + 25;
  }
}

let sp = new SoftwareProject();

sp.getTaskCount()
// 75