useEffect, useRef and useCallback with 1 project in Reactjs
ฝัง
- เผยแพร่เมื่อ 14 ต.ค. 2024
- In this video, Hitesh walks you through the practical use of ReactJS hooks like useEffect, useRef, and useCallback by building a simple yet insightful project-a password generator. Despite the project’s basic appearance, it’s designed to demonstrate ReactJS best practices, focusing on optimizing component re-rendering and enhancing user experience. Hitesh explains how useEffect runs code on component mount and re-runs when dependencies change, ensuring the password updates dynamically. The useRef hook is utilized to reference and manipulate DOM elements, such as highlighting text when copying. Additionally, useCallback is introduced to optimize performance by caching function definitions, preventing unnecessary re-renders. This project, built using Tailwind CSS for styling, is an excellent example of how even a simple ReactJS application can involve complex, efficient coding techniques. Throughout the video, Hitesh emphasizes the importance of understanding these hooks to write cleaner, more efficient React code, making it a must-watch for anyone looking to deepen their ReactJS knowledge.
Welcome to a youtube channel dedicated to programming and coding related tutorials. We talk about tech, write code, discuss about cloud and devops. That’s what we do all day, all year. We roll out a lot of series and videos on our channel.
All the learning resources such as code files, documentations, articles and community discussions are available on our website:
chaicode.com/
You can find our discord link, github link etc on the above website.
Twitter/X link: x.com/hiteshdo...
Discord link: hitesh.ai/discord
Learn React with 10 projects: • Let's learn react from...
Learn Docker: • A practical guide on D...
Learn Kubernetes: • Complete Kubernetes Co...
How does a browser works: • How does a browser wor...
How nodejs works: • How node JS works | En...
Learn Redux-toolkit: • Learn Redux Toolkit in...
Learn NextJS: • Nextjs Full stack course
Learn Typescript: • Why to learn Typescript
Learn Javascript: • Welcome to new JavaScr...
Learn React Native: • React Native Mastery: ...
Learn Zustand: • React state management...
Learn Golang: • How to get started wit...
What a way to explain things even after working 8 years in industry i find lot of point to pick and dig dive thanks HItesh SUperman
Hitesh, I love the tutorials! Clear, current, and easy to listen to and follow. Well done.
thank you what a beautiful way to deal with React I loved it. man I do not feel time with you this is an amazing series to learn with thanks again
this tutorial series is the best l have found on React. thank you so much Mr. Hitesh. BUG: Sir - there are instances the password generated is less than the length specified, it still displays for the user the password however it is shorter than the user selection. work around l used is to use an if statement to compare the length of the password generated against the "length" required, if they are not equal re-run the "for loop", l created a function for the "for loop" to ensure for loop is not repeated. thank you once again
Hey Hitesh!
You are the best speaker about programming that I've ever watched and listened.
Thank you very much
Thank you, again, this series has driven home so many of the skills I have been struggling with in react, thank you.
you are the best Hitesh. your teaching style is just out of this world and simple.
This series is the best for beginners trying to learn react. You make it sound interesting and easy to learn.
Thank you Hitesh sir
I actually was studying from chai and react and i came here to revise the videos that I've studied😅, and these videos actually helped me understanding concept more.
Great video. Simple and easy with that explananation
Hey Hitesh!
It was a wonderful, easy to understand, basic to detail, everything you have covered in this video🤩
Thank you so much for creating and updating such contents. Keep Going 🤓
Thank you hitesh for this series really i am enjoying this playlist and building a frontend project from scratch
Hi , thanks for your tutos , very interesting and helping a lot.
Juste a comment to tel you that there has been a small mistake in your code (nothing to bad).
In the "for loop" you wrote "i
right, or start the loop at 0
THis is the most valiable 40 minutes video i have watched in a while...good job!!!!
The way you help us make to understand concept in JavaScript , is superb.
thank you hitesh for this series. please continue this as long as as you can. Im learining a lot from this.
Yep, we will be building some cool mega project too in this series
Thank you for sharing this video series which helps so much for learning react from scratch
Anyone watching this, just know that you in the right place..
if i will complete this series will I be able to crack the interviews?
This is one of the best react series on yt❤
thank you Hitesh sir for this series.. Im learining a lot from this.
Thank You sir ..❤
i came here after watching 3 hrs video on another channel.
Great Project. Great Attitude. Great UI.
You are doing really good work. Your videos are always helpful for me. Thanks Hitesh 👍
Glad to hear that
Thanks, Hitesh. In general, I wouldn't comment, but I want you to make such more videos, hence I'm on it for your morale. Cheers.
Thanks a ton
Thank you for the series!
real hero in development
Thank you for the Quality of teaching, Sir
quite informative video learnt a lot in it. one little confusion, i did not get why we used "usecallbak" when "use effect" is doing the same thing.
very much interested sir... thanks so much for this series it help us a lot in our projects
You are most welcome
thank you what a beautiful way to deal with React I loved it.
Thank you for your free educational video.
Amazing video, learnt a lot of things, Thank you so much Sir🤩
Great effort towards quality of teaching
Your videos are always helpful for me.
Your videos are best so far
Thank you for this course sir , please continue this series as long as you can. ❤
there is problem in for loop , hence i tried - for (let i = 1; i < length; i++) {
const i = Math.floor(Math.random() * str.length + 1)
pass += str.charAt(i)
}
Vamossss...... you are an inspiration to many... bravooo 💪🏿💪🏿💪🏿💪🏿💪🏿💪🏿💪🏿💪🏿
From chai and code ❤
Excellent series so far. Just a quick question about the "onChage" method. When you write "onChange = {(e) => setlength(e.target.value)}," how does the javascript know to immediately interpret the "e" as the event? Thanks in advance!
The (e) is a shorthand for (event). It's a parameter that represents the event object generated by the browser when the onChange event occurs.Also the way function written here is with implicit arrow functions . Implicit return functions don't require any return keyword . (ES6+ JS Syntax)
Hello Sir, Great video, though one query , why we used dependency array on both useeffect and usecallback ?
Thank You sir, you are doing a great work!!!!
Thanks for giving this nice course
Thank you sir for this course❤❤
Thanks for this course and your work on this.
Really helpful series for learning to react
Great work, appreciated. 😃
100th Comment Hitesh Bhai
Why only 100 comments for this quality stuff.....
Thank you. Very useful video.
You are welcome!
Sir keep it up , i am following your both channels.
Keep watching
great Hitesh
Great tutorial!!
Im very much thankful to you sir
Thanks Hitesh...
Please, please keep going !
Keep going Bro! Great Job
Hitesh brother 💐💐
its really awesome
Thank you so much for this video
I love this react coding
Awesome. Learned about usecallback hook.
Glad it was helpful!
Nice explanation.
Could you please share which extension you're using to receive auto-suggestions in your code editor?
great work
Nice work bro
Let's go ❤
❤️
yes sir sooooo intrestedddddddd
how are you getting the auto suggestions when you are defining the states?
Intelisense or ai like tabanine, copilot,cody
Thanks Hitesh please can you do something on python. You are the best
much needed
Thanks 😊
Haanji you are back 😅
wonderful
🔥🔥🔥🔥🔥🔥🔥
Thankyou ji
thanks sir
nice
Thanks
thanks🎉
Ey intern hire kr rhe hain? Ey techthon comp sahi hai?
make more don't stop
guys, what extension prompts vs code to autocomplete useState snippets as shown in 09:40.
generatePassword function is working without useCallback.... why?
Starting easy project:- 🤡
Ending complex project:- 🗿
❤
Hy sir , there are several "Post Graduate Program In Cloud Computing" which offers Certification Aligned with AWS ,GCP, Azure and are providing industry lvl knowledge , practices , project developments and lot more , and are charging from 65k to 1.5 lakh having a course tenure of 6-8 months , wanted to know that is it beneficial to spend this much for these kindda stuffs, or just simply should pursue for individual certificates step by step (as u taught ) ,,
it will gonna be very helpful if u can plz clear this out , for each and every perspective (beginner, intermediate , pro ). 😊
Simplilearn ?
yep , any kinda info u know about ???@@ogawde7
Benefit is a very personal term. Each offering has it's own value proposition.
Day 3 of React Journey. 5th video of the day.
Thank you
You're welcome
♥♥♥♥
👍
♥
we are interested
Why in this channel less react video or u r uploading slowly... 😢😢
I upload as I get time from life 😁
Thank you hindi fan
❤️
Why bootstrap is not used here
Bootstrap, tailwind or any third party, this series is not focused on CSS
commenting for boost
Coffee and React
I am more of a tea person 😁
where is the code