The Image Uploader Trick You Didn’t Know – Avatar Preview with Cloud Storage!

preview_player
Показать описание
🚀 In this video, we’re building a sleek, real-time image uploader with an avatar preview! You’ll learn how to:

Select and upload an image seamlessly
Display upload progress with dynamic feedback
Update the avatar once the upload is complete

⚡ Plus, we’ll explore how to store images in cloud storage rather than traditional databases for optimal performance.

🔗 Resources:

💡 Tools/Libraries Used:

If this tutorial helps you, don't forget to smash the like button 👍, and make sure to subscribe for more awesome content like this! 🚀

⏱️ Timestamps:
0:00 - Introduction to image uploader demo 🎥
0:40 - Purpose of the tutorial 📚
1:20 - Setting up the project folder and opening VS Code 🗂️
1:56 - Creating a React app ⚛️
2:37 - Installing Daisy UI and Tailwind CSS 🎨
3:52 - Configuring Tailwind CSS and Daisy UI ⚙️
5:48 - Centering content using Tailwind CSS ⬜
6:51 - Using Daisy UI's avatar component 👤
7:45 - Adding a file input component 📂
8:41 - Creating a Cloudinary account ☁️
9:49 - Retrieving Cloudinary cloud name and preset name 🔑
12:42 - Creating an image upload function 📤
14:09 - Setting up file upload with form data 📄
16:13 - Calling Cloudinary's API with file data 🌐
17:20 - Handling response and errors from Cloudinary ❌
18:42 - Exporting and using the image upload function 📦
19:01 - Defining the handle upload function ✍️
19:17 - Event handling for file upload 🔄
19:25 - Extracting the file from the upload 📥
19:31 - Checking file type and size ✅
19:37 - Reading the file data using FileReader 📖
19:49 - Processing the file data after successful read 🔍
19:53 - Updating the UI based on the upload result 🔄
20:11 - Updating the database or state with the uploaded file information 💾
22:40 - Changing upload preset ⚙️
23:11 - Accessing URL from response 🔗
24:12 - Fallback image condition 🌄
24:59 - Showing upload status ⏳
26:29 - Displaying uploaded image 🖼️
27:00 - Conclusion of tutorial 🎉
27:10 - Project links and resources 📥

🎉 Thanks for watching! I hope you enjoyed building this real-time image uploader with me. Remember to hit subscribe and stay tuned for more tutorials!
Рекомендации по теме