replace __defineGetter__ and __defineSetter__ on the prototype with defineProperty
<p>I currently use the following syntax to define a class with getters and setters.</p>

<pre><code>SomeObject = function() {

  this._propertyOne = 'test';

}

SomeObject.prototype.__defineGetter__('propertyOne', function() {

  return this._propertyOne;

});

SomeObject.prototype.__defineSetter__('propertyOne', function(value) {

  this._propertyOne = value;

});
</code></pre>

<p>Then I can access the property like this:</p>

<pre><code>var o = new SomeObject();
o.propertyOne = 'test2';
console.log(o.propertyOne);
</code></pre>

<p>How can I achieve the same with the non-deprecated defineProperty command or something similiar?</p>

<p>I tried something like this:</p>

<pre><code>Object.defineProperty(SomeObject.prototype, 'propertyOne', {
  get: function() {

    return this._propertyOne;

  }.bind(this),
  set: function(value) {

    this._propertyOne = value;

  }.bind(this)
});
</code></pre>

<p>But it doesn't work.</p>
