Software Engineer

Hack Reactor Remote Prep Week 3

· by Justin Zimmerman · Read in about 2 min · (307 Words)
Hack Reactor Remote Prep

Week 1 | Week 2 | Week 3 | Week 4

I cannot believe we have already completed 3 weeks of class! I have learned a considerable amount along the way. Here are some of the topics that were covered this week.

Functions

Now we are getting into the good stuff. Functions are one of the most critical tools for any good JavaScript programmer. We discussed creating functions, invoking functions, and storing functions as variables.

Events

Event handlers are specific types of functions that are invoked when the user interacts with the website. For instance, text can be shown when a button is clicked, or an image can appear when a mouse hovers over a text link.

Arrays

Arrays are one of the primary methods for storing data collections in JavaScript. An array is used to store ordered lists. Arrays can include all sorts of different data types, booleans, strings, numbers, objects, and even arrays within arrays.

We discussed array instantiation, and the associated properties (such as .length) and methods (such as .push or .pop) that come with arrays.

Objects

Objects are the other primary method for storing data collections in JavaScript. Rather than an ordered list of values like an array, objects are stored using key value pairs. These keys can be referenced using dot notation or bracket notation.

We then used both dot notation and bracket notation to access values that were stored within the objects.

Web Store Hackathon

This hackathon was an individual 3 hour exercise in building a web store to compete with Amazon.com. We built upon our existing knowledge of HTML, CSS, and jQuery to create a basic layout for our e-commerce site. We then used objects to store our products that we would be selling, such as books and albums.

Week 1 | Week 2 | Week 3 | Week 4

Comments