SyntaxFix
Write A Post
Hire A Developer
Questions
Just to add,
const foo = function(){ return "foo" } //this doesn't add a semicolon here. (function (){ console.log("aa"); })()
see this, using immediately invoked function expression(IIFE)