How to return object of constructor from inside the constructor
<p>How can I return the object from constructor from inside the constructor?</p>

<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code> function consFunc() {
  
    this.flag = 'someFlag';
    this.pol = 'somePole';        

    }

    consFunc.prototype.foo = function(){      
     console.log(this.flag);
    }

    var obj = new consFunc();
    obj.foo();</code></pre>
</div>
</div>
</p>

<p>This is how usually I make object from constructor. How can I return object from inside the constructor function so I no need to write  <code>var obj = new consFunc();</code> I just simply call <code>obj.foo();</code> for my need, is it possible?</p>