While writing a javascript course for some coworkers, I accidently discovered an alternative syntax for self-invoking function. Does anyone know about it, is there some specifics to it ? I wasn't able to find documentation about it.
CODE : classic syntax
(function(){
console.log("I'm self-invoked!");
})();
alternate syntax
(function(){
console.log("Me too!");
}());
Thanks for the hints !