During the past week of the Web Development Immersive at General Assembly, we’ve focused on becoming more familiar with JavaScript. Having mostly worked with Ruby, it was a bit jarring at first to lose some of the syntactic sugar I’ve grown accustomed to. But for all of the additional semicolons, parentheses, and curly braces, I’m itching to do more work in JavaScript. Why?

Asynchronicity

JavaScript allows us to execute code once certain events are triggered. As a developer, I now have the ability to update the DOM easily whenever a specified event—the end of a timed interval, a user clicking on a button, etc.—takes place. All without the browser needing to reload the page! This felt like magic until I watched Philip Roberts’s JSConf EU talk, which provided a great explanation of how JavaScript interacts with web APIs.

Thinking more about UI

With the ability to work with the DOM asynchronously, we now can give a bit more thought to how our users will interact with our applications. Although we’ve been able to style our pages with CSS, we haven’t really had a way to make them feel interactive. But with JavaScript, we can make our applications easier and more intuitive to use. For example, as one of our first exercises using jQuery, I built this simple Connect Four-style game. Some of the effects would have been impossible in pure HTML and CSS, but are accomplished more readily using JavaScript.

Powerful frameworks

What I’m most excited about when it comes to gaining JavaScript fluency is working with some frameworks like Angular and Ember. I’ve read a little about both of these frameworks and some others, and they all seem to have some very powerful capabilities. Data binding, giving users links to return to the application in a specified state, among other features, will be fun to play around with as I work on some new apps.