title: Why use a static function that returns new this() instead of a constructor?
body: <p>While reading some open source code, I came across this (cleaned up) snippet of code below.</p>
  
  <pre><code>class Foo  {
  
      constructor(bar) {
          this.bar = bar;
      }
  
      static create(bar) {
              return new this(bar);   
      }
  }
  </code></pre>
  
  <p>My question is why would someone use a static function that returns new this() instead of a constructor?</p>
  
  <p>Are there any differences between <code>new Foo(bar)</code> and <code>Foo.create(bar)</code>?</p>