Here, we will learn about the immediately invoked function expression or IIFE for short. This is a common way to address variable privacy if using the old school var to declare a variable.
0:00 What is an immediately invoked function expression
0:39 Expressions in JavaScript
1:24 Creating an IIFE
4:05 How to call an IIFE
4:23 Showing variable privacy
5:58 Creating a block for variable privacy with let or const
7:48 Showing problems with var
9:08 Passing arguments into an IIFE
JavaScript Playlist:
https://youtube.com/playlist?list=PLgIi4lM74yW2Mc8iFRJMgvamNWOOFDH-q
MDN IIFE:
https://developer.mozilla.org/en-US/docs/Glossary/IIFE
NodeJS:
nodejs.org
VS Code:
code.visualstudio.com