Is there any difference in the two definitions and assignments of functions?
this.foo = new (function () {..})();
vs.
this.foo = function (){...};
In the first example, it's creating a function and executing it, assigning the result to this.foo. In the second example, it's creating the function and assigning the function itself to this.foo.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With