class shape { constructor(sides) { this._sides = sides; } get sides() { return this._sides; } static makeShape(sides) { return new shape(sides); } } const triangle = shape.makeShape(3); // triangle.sides = 3