title: Typescript - What is better: Get / Set properties
body: <p>Just recently discovered about using get and set keywords for class properties I was wondering what is the preferred method when using get / set for typescript classes:</p>
  
  <pre><code>class example {
      private a: any;
      private b: any;
  
      getA(): any{
          return this.a;
      }
  
      setA(value: any){
          this.a = value;
      }
  
      get b(): any{
          return this.b;
      }
  
      set b(value: any){
          this.b = value;
      }
  }
  </code></pre>
  
  <p>I am just curious if there are any best practices, performance, or other factors.</p>