Learning Objectives
- AJAX Concepts
- How to use JavaScript to make AJAX requests
- Use AJAX callbacks to respond to server responses
- How to process JSON with JavaScript
Materials
No Odin Project materials this week. Instead, please read and watch the following then visit the link for the Tutorial below. Additionally (or instead) you can look at the Treehouse lesson for the week: AJAX Basics (149 mins)
AJAX is the “old” method of handling API calls. Next week you’ll learn about the newer/best practice way of handling API calls. We want you to learn this old way first because it helps demonstrate what an API is and how it works (how data is transferred to and from a client/user and a server where data is stored). Watch this video and read this tutorial to get an understanding of AJAX. JSON is the common way data is returned from an API call. This video will also talk about JSON and how to work with data in that format.
- Video:
- Tutorial: Free Code Camp – AJAX tutorial
Assignments
Coding Assignment
This week you will be learning how to fetch data via AJAX. Your lesson can be found here:
Mindset Assignment
A few weeks back we discussed how to effectively ask for help. Feel free to review that topic and your answers this week (link to that week’s lesson here). We’ll be talking about asking for help again, but this time let’s focus on the when since we’ve already covered the how.
At the beginning of this course you may have wanted to ask for help as soon as you hit a problem and before you even tried to debug or problem solve on your own. You don’t have to do that anymore since you have those problem solving and debugging processes we’ve been talking about. But the opposite can happen too; sometimes you get so determined to solve the problem on your own that you spend hours longer than you needed to trying to fix something, when asking for help could have saved you time and frustration.
Read this article about knowing when to ask for help at work, then answer the following questions:
– Have you implemented/used any new strategies since the previous post on how to ask for help? If so what were they and how did they turn out for you?
– After reading the article what changes (if any) will you make to your strategy?
– What are some ways you can determine which “circle” (inner circle of things you know, middle circle of things you can figure out on your own, outer circle of things you don’t know and can’t learn by yourself) your blocker/bug/issue falls into?
When you’ve completed your Coding Assignment, and have read and thought about the mindset questions above, submit ALL of your assignments (link to your pull request on GitHub and mindset) using the Homework Assignment Submission Form.