I have some code:
"use strict";
class Node {
constructor() {
}
}
class Person extends Node {
constructor() {
}
}
const fred = new Person();
Run in Node v4.2.4 it gives the error:
ReferenceError: this is not defined
at Person (/home/chris/test.js:12:3)
Where line 12 is the closing bracket of Person::constructor.
Why can't I extend the Node class?