//Given the class A: class A { constructor() { this.a1 = ""; this.a2 = ""; } } //you get the properties with: let a = new A(); let array = return Object.getOwnPropertyNames(a);