Loading...
「ツール」は右上に移動しました。
利用したサーバー: wtserver2
9いいね 115回再生

Episode 4: Enhance the Tasks API with User Association

Welcome to Episode 4 of our tutorial series! 🎉 In this episode, we’re taking the Tasks API to the next level by adding User Association, enabling multi-user functionality for your app.

🔑 What You'll Learn:

Create a users table to store user information 🧑‍💻
Add a foreign key to associate tasks with users 🔗
Update your endpoints to handle user-specific tasks 📋
Implement new user-related endpoints for CRUD operations 🚀
💡 By the end of this tutorial, you’ll have a multi-user Tasks API that’s more versatile and ready to integrate into real-world projects!


Timestamps:
00:00 Objection behind this lesson
00:48 Why associate tasks with users
01:14 Key Concepts
01:53 Project Architecture
02:14 Key Features
03:00 User and Tasks Diagram
03:25 Steps we will take
04:07 Code Section
04:20 Enable foriegn Key constraints in SQLITE
04:23 Schema changes
05:36 relation added to tasks table
05:58 DB file creation
06:18 DB generation
07:50 Drizzlekit studio server run
08:27 Viewing our DB in drizzlekit
09:27 Adding Users to drizzle kit
10:50 Creating Tasks as Users
13:19 API changes to users route
15:15 Find User by ID
15:35 Create User
16:01 Delete User
16:16 Update User
17:40 Fetch Tasks by User ID
18:28 Testing our API endpoints
19:17 Creating Task Request example
20:05 Fixed task bug
20:25 Create Task API updates
21:12 Fetch all Tasks Request example
21:42 Extra features we can add to the app
23:00 Next possible updates

📁 GitHub Repository:
Branch: Episode4-UserAssociationWithTasks
Source Code: github.com/enrise-tech/first-crud-api-hono/tree/Ep…

🌐 Enrise Tech Blog: www.enrisetech.com/
📹 YouTube Channel:    / @techwithgiordi  
🐦 Twitter: x.com/enrise_tech
📧 Email: enrisetech@gmail.com
💬 Discord: discord.com/invite/geAgvJJJtE
👍 Don’t forget to like, subscribe, and share!
If you found this tutorial helpful, hit the bell icon 🔔 to stay updated on our latest uploads! Let’s build something ama

コメント