Forms and Client-Server Interaction

Overview


So far, in the course, we’ve looked at building client-side functionality and server-side functionality separately. While client-side functionality provides user interface and a rich user experience, the server-side functionality provides APIs and data storage.

In this part, we look into integrating the two parts to create applications where the client interacts with the server. We start by learning about HTML forms, which make it easier to collect user input. Then, we look into the Fetch API, which is a standard way to make HTTP requests using JavaScript, and discuss the same-origin policy and cross-origin resource sharing (CORS) and their implications. This is followed by constructing functionality to interact with server-side APIs, and integrating this with shared state. Finally, we look into error handling when interacting with APIs.

The structure of this part is as follows.

Finally, at the end of the part, there is a recap and feedback chapter that briefly summarizes the part and asks for feedback on the part.

Research follow-up

0 / 5 points

Earlier in the course, we asked for your help by participating in a study investigating factors related to learning. This is a follow-up survey, which takes about 5 minutes to complete. You may choose not to answer truthfully, and you can also decide whether your responses may be used as part of the research.

Click here to take the survey

Once you have answered the survey, return here and paste in the code you receive at the end of the survey.