Свойства класса JavaScript List

function getClassProperties(instanceOfClass) {
  const proto = Object.getPrototypeOf(instanceOfClass);
  const names = Object.getOwnPropertyNames(proto);
  return names.filter(name => name != 'constructor');
}
NeuroticVegan