DEV Community

Discussion on: What Do You Know About JavaScript Closures?

Collapse
 
kmwill23 profile image
Kevin

Hard topic to explain, for sure. I actually told a really bright new dev on my team that once they have recursion figured out, we'll talk about the complexities of JS, scope, and closures.

Last year I actually started reducing the amount of closure scope I use in JavaScript. The performance benefits when browsers don't have to load scope is amazing.

Collapse
 
heindauven profile image
Hein Dauven

Practical real world examples that allow people to achieve that 'a-ha!' moment is really key, else it's just theoretical mumbo jumbo to most.

That would make an interesting article! Performance implications of closures.