DEV Community

Discussion on: Discover the Power of Closures in VueJS

Collapse
 
jamesthomson profile image
James Thomson

Great write up. Closures are an integral building block when learning JavaScript. 👍

Btw, you have 2 very, very minor things that need correction in your code examples

console.log(squareB); // ReferenceError: squareX is not defined.

should be // ReferenceError: squareB is not defined.

and you call hallo(); // B C, but hallo() isn't a function ;)

Collapse
 
hinsencamp profile image
Fabian Hinsenkamp

Thanks James, good catch!