• Online, Self-Paced
Course Description

This 14-video course covers closures, the bundle of a function along with its enclosing environment, and its implications on factors such as variable scopes and function references. Key concepts covered here include what makes up a closure in JavaScript; learning how variables of the same name inside closures and in scopes outside them are accessed by functions; and distinguishing between variables of the same name inside functions, within closures, and ones defined in a global scope. Begin by observing how to implement counter functions with closures; how to integrate closures with buttons on web pages; and how closures can be created within objects and implications on your code. Next, learn how closures created within loops interact with variables defined within and outside the loop; how to implement getter and setter functions for JavaScript objects using closures; and learn when to use prototypes for objects and how to define them. Finally, observe how to distinguish between object prototypes and classes; learn to use prototypes to implement inheritance; and implement multiple levels of inheritance with prototypes.

Learning Objectives

{"discover the key concepts covered in this course"}

Framework Connections

The materials within this course focus on the Knowledge Skills and Abilities (KSAs) identified within the Specialty Areas listed below. Click to view Specialty Area details within the interactive National Cybersecurity Workforce Framework.