JavaScript Closures
You need to know how the lexical scoping works first to understand the closures. Lexical scoping Lexical scoping defines the scope of a variable by the position of that variable declared in the source code. For example: let name = 'Ravindra'; functi...
May 18, 20222 min read149
