Posted on May 23rd, 2022
🗓️ Today’s Topics
- How AJAX and APIs work
- The useEffect hook
- How to make AJAX calls from React using Axios
🎯 Project
This project is due next Monday. We’ll check in on progress at each class meeting between now and then.
React Trivia. Your goal today is to get a list of trivia categories showing on the page.
🔖 Resources
AJAX in React
useEffect()
How to Think About Building Things in React
Conditional Rendering and Handling Events
👾 Code
Posted on May 23rd, 2022
🗓️ Today’s Topics
- Show your finished Habit Tracker
- HTTP requests and responses
- REST APIs
- Django REST Framework
🎯 Project
Complete the official Django REST Framework tutorial. You may find it easier going if you follow the guide by Will Vincent.
Will Vincent uses the exact same code and steps but is much more beginner-friendly. He also uses pipenv
for the virtual environment like we do. Will’s tutorial stops short of the last step, step 6, in the official tutorial. But if you finish step 5 and want to keep going, you can continue with the official tutorial.
You should complete the tutorial by tomorrow.
⛔ Do not copy & paste the code. You’ll get a lot more out of it if you type it out yourself.
📖 Read | 📺 Watch | 🎧 Listen
ICYMI 👀
These links were posted last week, but you may not have gotten to them.
🔖 Resources
👾 Notes
Posted on May 19th, 2022
Today’s Topics
- What did you learn from the tutorial(s) you did? First impressions of React?
- Build a small React app together in class
- Components and JSX
- Handling data in React with props and state
🎯 Project: Freeshelf
Today, you’ll start on your first React app without a tutorial. This is due on Monday.
React Freeshelf
🧰 Please be sure to install the React Developer Tools for Chrome.
📖 Read | 📺 Watch | 🎧 Listen
🔖 Resources
🦉 Code and Notes
Videos for React Devs for Hire
Posted on May 19th, 2022
Today’s Topics
- Interacting with models in the shell
- Queries and more queries
🎯 Project: Still Working on Habit Tracker
Habit Tracker is due on Monday. You can do this! 💪 What do you need to figure out in order to finish it?
📖 Read | 📺 Watch | 🎧 Listen
- Database Design for Beginners This is a talk from RailsConf, which is focused on Ruby on Rails. Rails is a framework for building web applications in Ruby, very similiar to Django. It’s an excellent introduction to how to think about your data model – that is, the logic that drives the decisions you make about the models in your code and the structure of your database. Please watch it all the way through; even though it uses Ruby examples you should be able to get the gist.
This rest of this section is material to prep for the topic we will begin next week: building APIs.
🔖 Resources
Using the shell (the interactive REPL, not pipenv shell)
🦄 PRO TIPS
django-debug-toolbar
has a SQL panel that will show you the queries you are running in the view.
- With
shell_plus
, you can see output of all the SQL queries if you run it like this:
python manage.py shell_plus --print-sql
Lookups
Constraints
Aggregate & Annotate
🦉 Code & Notes