I'm aware that a JavaScript function can be defined in this form
function name(parameter1, parameter2, parameter3) {
// code to be executed
}
which consists of function
keyword, followed by a name, followed by parentheses (), followed by curly brackets: {} in which the code to be executed is placed.
However, lots of real world js files look like this
(function(){...})();
where ... might be tens of thousands of lines, like this one which has 2 big blocks there.
Is that a form of JS framework? In the example of howler.js
, the link above gives the source code of that framework which consists of 2 packages that are in the form of 2 block like (function(){...})();
Is my understanding correct?