how could I get all property names of a subclass in typescript? I'm able to get all property names in the class, but it also gives me the ones in the base class, which I don't need.
base class
class BaseTestClass {
public testVar: null = null;
}
sub class
class TestClass extends BaseTestClass {
public longNameVar1: null = null;
public longNameVar2: null = null;
public longNameVar3: null = null;
public longNameVar4: null = null;
public longNameVar5: null = null;
}
let testClass = new TestClass()
let testClassProperties = Object.getOwnPropertyNames(testClass)
console.log(testClassProperties);