Day 15 jQuery

Day 15 is in the books and week 4 is underway. This is going to be a big week. We are covering a lot of material. Next week we start our Q1 projects which seems crazy. I can’t believe we’re almost done with the first quarter of the program.

jQuery is a javascript library designed to make selecting and manipulating the DOM a bit easier. It has an abbreviated syntax that speeds things up as well as some built in smarts that make things like AJAX calls easier. There’s no magic involved in jQuery. Under the hood it’s nothing but vanilla javascript and built in DOM methods, but that doesn’t mean it’s not powerful. If you’re going to be doing a lot of DOM manipulation jQuery can speed up your workflow significantly. It can be abused though and isn’t necessary for all use cases. For example if your application doesn’t do a lot of DOM manipulation and you aren’t doing AJAX calls you might be better off not bringing in the jQuery library. In order to use jQuery you have to load in the library via download or CDN and this uses a lot of resources that might not be worth it in every scenario. It’s important to use the right tool for every job and with javascript there are a lot of tools at your disposal. It takes some skill to understand the bigger picture and make wise choices with the resources you are using in your projects.

After doing a few exercises using the built in DOM methods I couldn’t help but think about how much easier they would have been if I’d had jQuery at my disposal. However, I can definitely see the value in knowing how to use the built in resources. They are more than sufficient in a lot of cases and are pretty straightforward to use. I think I’m going to go back through some of the exercises and do them with both jQuery and built in methods and weigh the pros and cons to each. I’m learning that doing exercises more than once and trying out different ways to solve problems is extremely useful in solidifying my learning. I don’t always have time to do as much as I would like to, but I try to do as much repetition as possible when I have the time.

Tomorrow we are learning how to make AJAX calls. AJAX stands for Asynchronous Javascript and XML. It’s an outdated name to be sure since not many APIs send back XML anymore. Pretty much everything is formatted in JSON these days. AJAX calls allow you to send requests to APIs (Application Program Interface) and receive back data. Lots of companies allow certain information to be accessed via and API and this is very useful as a developer. Once of the assignments later this week requires us to make AJAX requests to a database that contains movie information. We then have to parse that data and populate into our HTML structure. All of the pieces for the front end are starting to come together. We now know how to create and style HTML with CSS. We can manipulate the DOM to make our sites dynamic using javascript and jQuery. We will soon now how to get data from APIs and use it in our applications. We also have the ability to manipulate the data we get back using javascript. Things are starting to get fun! I’m excited to see what I am able to put together for my Q1 project. It will be here before I know it. I’ll be sure to share the results with you guys soon enough. Stay tuned for more info on that soon.

15 down 85 to go!

Show your support

Clapping shows how much you appreciated Jon Ramer’s story.