Skip to content

Instantly share code, notes, and snippets.

@easierbycode
Created April 29, 2016 19:50
Show Gist options
  • Save easierbycode/887dc2ab04d6763f9fb0979a398da027 to your computer and use it in GitHub Desktop.
Save easierbycode/887dc2ab04d6763f9fb0979a398da027 to your computer and use it in GitHub Desktop.
new.target points to the initial constructor
class Project {
constructor() {
console.log( new.target );
}
}
class SoftwareProject extends Project {
constructor() {
super();
}
}
var sp = new SoftwareProject();
// constructor() {
// super();
// }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment