Learn useEffect In 13 Minutes

  Рет қаралды 848,745

Web Dev Simplified

Web Dev Simplified

Күн бұрын

Пікірлер: 777
@patricktkinter
@patricktkinter Жыл бұрын
I knew he was going to be good when he starred directly into my soul
@romaniecumtehului6792
@romaniecumtehului6792 3 жыл бұрын
I paid money for a full react course on udemy and after every hook I "learn" from there, I come to your channel to see it reexplained better. 😅
@bishnudas3562
@bishnudas3562 3 жыл бұрын
course by whom?
@yudhochristin
@yudhochristin 3 жыл бұрын
Me too! hahah!
@slayer5171
@slayer5171 3 жыл бұрын
Yes, me too..
@qndev
@qndev 3 жыл бұрын
Me too. lol
@luizsoares4847
@luizsoares4847 3 жыл бұрын
Lol me 2
@ThatGuyAnonymous
@ThatGuyAnonymous 4 жыл бұрын
You have the gift of breaking down any difficult topics in a way that everyone can understand. I wish there was a super like button on KZbin 👍
@TheImprenditore
@TheImprenditore 4 жыл бұрын
I thought so too, he can probably bundle this up and make it into an in-person bootcamp and charge 15k per head.
@underlecht
@underlecht 4 жыл бұрын
yes, he is that guy.
@cba88
@cba88 3 жыл бұрын
super like from here
@KanchanSharma-bg2yh
@KanchanSharma-bg2yh 3 жыл бұрын
I saw many videos on hooks before, but this one only makes me understand completely in detail and in first attempt only. Thank you so much.
@deansprivatearchive
@deansprivatearchive 3 жыл бұрын
The subscribe button.
@michaelbarbarelli3764
@michaelbarbarelli3764 Жыл бұрын
The fact that the clean-up code runs before the event listener is a key point that's rarely communicated in docs, tutorials, etc. Very well done!
@lukas.webdev
@lukas.webdev Жыл бұрын
Yes, I agree 100%! 😉
@loneWolff1995
@loneWolff1995 8 ай бұрын
Can you explain Two things why App being rendered twice, when you click post twice, I mean when you clicked first time, I understand app being rendered, but when you clicked again on Post. The app shouldn't get rendered as state is already same. Second why useEffect ran twice, even though you are not using StrictMode *Kindly help !!!!*
@aaronmotacek9343
@aaronmotacek9343 2 жыл бұрын
One note at 5:00 for people newer to React. If you try to update state with setState (setResourceType in this case), but the value is the same as the current state, it won't trigger a rerender. This is because of the way the React team has chosen to implement useState (it helps to prevent unnecessary rerenders). This can become an issue when your state is an array (or an object), as you can mutate the array, try to update state, and it may not trigger a rerender because React thinks the array is the same (since the array reference is the same). You can solve this issue by using the spread operator (...) to create a truly new array or object: setState([...array]) or setState({...object}). More info on that at if you Google something like "usestate update not always triggering rerender component"
@nemanjastankovic941
@nemanjastankovic941 2 жыл бұрын
Thanks for this heads-up. It's something really useful to know
@prince5922
@prince5922 2 жыл бұрын
Correction: if you use _setState_ it will always re-render.
@vapeurdepisse
@vapeurdepisse 2 жыл бұрын
I found that out early on. There is this rule in React that "one simply doesn't mutate state" and it applies to hooks as well. React uses Object.is() to check for equality between the previous state and the new state, and if you mutate an array or object, it is still the same object and so it won't update.
@mrmartinwatson1
@mrmartinwatson1 2 жыл бұрын
@@prince5922 no
@tmode9303
@tmode9303 2 жыл бұрын
@@prince5922 No, it the value is same as before it won't re render. You need to spread
@learningdevelopment7429
@learningdevelopment7429 4 жыл бұрын
You are incredible! I'm self taught and employed as a full stack engineer, so I've been able to find some high quality tutorials on my journey. But you my friend, are truly an incredible teacher on intermediate/advanced language topics and I hope you continue to keep making these vids!
@makanmusty
@makanmusty 3 жыл бұрын
ditto man! hes a beast!!
@tapstothebeat
@tapstothebeat Жыл бұрын
3 different YT videos taught me how to use the useEffect hook but I only learnt it when I saw your video.
@zentaitamas
@zentaitamas 3 жыл бұрын
This is the most understandable explanation I’ve ever found. Good job mate and thanks.
@23Kattayopp
@23Kattayopp 6 ай бұрын
Kyle, every single time I feel that I don't understand something as good as I'd want, either it's html/css/js or react, I go and search a video on that subject from you. It's been a year and a half and it worked every single time. And I want to thank you for that! You're awesome.
@niloben659
@niloben659 Жыл бұрын
Once again knocking it out of the ballpark
@hniehslimi2894
@hniehslimi2894 Жыл бұрын
This is the most understandable explanation I’ve ever seen
@darwinduranalba2539
@darwinduranalba2539 3 жыл бұрын
dude I wish I had met this channel sooner. You're amazing
@IMChristianLowe
@IMChristianLowe 3 жыл бұрын
I'm primarily a backend/infrastructure dev and have been struggling with some very basic React concepts. I watched your useState video first and you did a fantastic job breaking it down and simplifying it so that my smooth brain could understand it. You've done a fantastic job here too. Well done!
@veoquenoesunproblema
@veoquenoesunproblema 3 жыл бұрын
Man, I have the same issue, of course I'm just a student right not, but the useState was a killer video for me. With that video I understood a lot of react but this useEffect is mind blowing, really funny how a lot of people love React but it is kind of complex to get it when you advance to the second page which is like, man is this so freaking easy? hah
@alexcastro9157
@alexcastro9157 3 жыл бұрын
@@veoquenoesunproblema That is because people are learning ONLY React, which relays on JS, pretty much. Good video, however this guy like almost ALL people try to assign the lifecycle to useEffect. But it is not pretty much the case because functional components behavior different from react classes, Dan explained in its blog ALL DETAILS. Also this guy does not talk about Closures and why it is important to know them... (Course because people do not learn javascript but react)....
@muhammadhafizuddin2965
@muhammadhafizuddin2965 19 күн бұрын
@@veoquenoesunproblemayess, bcs react brings a lot of new concept that differs from how js works. I also having a quite hard time when learning it, because we built enterprise app and the last project uses angular. So for this new project, i have to learn react and next js as that is what have been chosen by the architect.
@muhammadhafizuddin2965
@muhammadhafizuddin2965 19 күн бұрын
@@alexcastro9157yes, bcs this guy is not teaching js so ofc he wont talk abt closures. Closure is not react, its vanilla js.
@Hidiho2u
@Hidiho2u Жыл бұрын
I understand more in the last 30 minutes than I did 8 hours of lectures and workshops ago. Thank you so much!
@JosephLKausi
@JosephLKausi Жыл бұрын
Wow thank you, bro, now I have a clear idea on useEffect
@calarcher4869
@calarcher4869 2 жыл бұрын
every video of yours i search for because I am trying to understand a seemingly impossible concept, I leave 15 minutes later having a great understanding. 100% live up to your name, Web Dev Simplified
@cafuune
@cafuune Жыл бұрын
was struggling all day with this thing, now its like crystal clear lol thank youuuu
@BobbyBundlez
@BobbyBundlez 4 жыл бұрын
wow. never seen state being used to fetch data dynamically like that with the press of one button! awesome!
@snovich_117
@snovich_117 3 жыл бұрын
close to nine months not understanding useEffect, thans for your help. It was the best one
@millicentmalinga962
@millicentmalinga962 8 ай бұрын
The name of the channel really speaks for itself. Thank you for this
@darkdevilxy457
@darkdevilxy457 2 жыл бұрын
I have to say this is the best explanation of react hook
@shakirbaba3978
@shakirbaba3978 2 жыл бұрын
You tone is so smooth I can understand you code without looking at screen. Thanks for such great videos
@Lingchao2596
@Lingchao2596 Жыл бұрын
One of the best tutorials ever
@rishabhtripathi6465
@rishabhtripathi6465 4 жыл бұрын
Kyle is the best ,he explains so much things in a very time span.Other channels sometimes confuses me with so much mess.
@user-yz5hj3zg2x
@user-yz5hj3zg2x Жыл бұрын
FINALLY!! After reviewing a ton of tutorials and explanations, I could finally understand what this hook was for! Thanks a lot!
@zouhairsahtout9682
@zouhairsahtout9682 Жыл бұрын
Thank you so much you really did explained the 'clean up' and how it works exactly, and that is always useEffect run the returns first so if you have any event listener already should gets deleted so you don't ends up with another event listener, if your useEffect gonna create an event listener to listen for something. God bless you man
@lukas.webdev
@lukas.webdev Жыл бұрын
Yeah, that's a very important point! 😉
@s.bamahfoodh
@s.bamahfoodh Жыл бұрын
that was really great. I feel like I understand ever slightly more
@gmzcj
@gmzcj 3 жыл бұрын
He isn't joking when he says his job is to simplified the web. Very easy to follow!
@mashaisalive
@mashaisalive Жыл бұрын
один из немногих на ютубе, кто реально понятно объясняет. god bless him
@brannonmay
@brannonmay 2 жыл бұрын
Any time I watch your videos, you connect the dots for me. Thank you for everything.
@yauhenistankevich3503
@yauhenistankevich3503 Ай бұрын
those 15 minutes videos gave me more understanding than a week of self learning😁
@awesomejs
@awesomejs 4 жыл бұрын
So many times used useEffect but now i understand properly, respect for you sir.
@sameer.bhardwaj7585
@sameer.bhardwaj7585 Жыл бұрын
Bro does look like someone named Kyle. Love your content
@filipozbolt
@filipozbolt 3 жыл бұрын
6 minutes of this video and i understand use Effect, something that i didnt understand in one hour lesson. Thank you very much 😊
@dimaster5880
@dimaster5880 4 жыл бұрын
Wow, this is the best explanation I have ever seen so far. My respect.
@shadmanmartinpiyal4057
@shadmanmartinpiyal4057 3 жыл бұрын
wow.. that clean up thing just blew my mind. I have been a react developer for a while now, still didn't know this. Well everyday we learn, we grow.
@KaranSharma-ew7io
@KaranSharma-ew7io 3 жыл бұрын
Everything about you is cool , from hairstyle to voice to explanation
@gunnarMyTube
@gunnarMyTube 3 жыл бұрын
Learn from the enlightened
@cristianouzumaki2455
@cristianouzumaki2455 4 жыл бұрын
I would like to know from those who disliked like exactly what did you not like. This is one of the best useffect exp out there.
@riyadzaigirdar5394
@riyadzaigirdar5394 4 жыл бұрын
He didn't explain the why it renders, bacause the state changed..and also print 2 renders so...one for the jsx other for the state change....and he should have also shown an example of setTimeOut in Useeffect
@cristianouzumaki2455
@cristianouzumaki2455 4 жыл бұрын
@@riyadzaigirdar5394 If you are trying to learn a hooks concept it's logical that you know basic react concepts like state change impact and setTimeout is a js concept, why learn react when one is not aware of js concepts.
@riyadzaigirdar5394
@riyadzaigirdar5394 4 жыл бұрын
Those are morons, dont think of them...they will have more "why's" in life then "yes"
@manoranjands9479
@manoranjands9479 Жыл бұрын
Finally I understood the concept...wow what a way of teaching man...! So simple and understandable. Thank you so much
@lukas.webdev
@lukas.webdev Жыл бұрын
I agree! 😉
@user-gq1ij
@user-gq1ij Жыл бұрын
​​@@lukas.webdevAt 10:00, how is useEffect called, even though the array is empty and having no change
@siddharthmehta6966
@siddharthmehta6966 2 жыл бұрын
This is the best explanation one can get on internet !!!! Simply wow . Thanks for the tutorial
@badrivelamurasokan837
@badrivelamurasokan837 3 жыл бұрын
You definitely have the teacher mindset. Really clear!
@extrouzex1070
@extrouzex1070 4 жыл бұрын
This guy is really awesome, talking too slowly but telling a lot of the topic for making it much easier, love u man 💚
@rodrigom.castilho4095
@rodrigom.castilho4095 4 жыл бұрын
Solved a massive pain in the ass 4 minutes, 6 seconds in. Best subscription I ever made here.
@archdetective
@archdetective 2 жыл бұрын
I had better luck with you than my prof. Thanks a lot!
@riturathinsharma5931
@riturathinsharma5931 4 жыл бұрын
You are a genius. The way you explain things and connect the dots is simply awesome. It is very easy to connect to what you explain and easily get accustomed to new technology . Great Going bro, keep it up :)
@johnnielondon9840
@johnnielondon9840 Жыл бұрын
I’ve now watched a couple of your videos for different react hooks and they’re great. Really clear and to the point. Thank you Kyle
@chandrakant6283
@chandrakant6283 2 жыл бұрын
Extremely Useful, I've just picked up react and these small doses of lectures are really making the difference. Thanx, Kyle.
@Aresqn87
@Aresqn87 3 жыл бұрын
The best REACT explanation on KZbin. Thanks.
@bigbabyg
@bigbabyg Жыл бұрын
honestly, along with this dope explanation, i recommend just reading the react docs, they are well explained and easy to digest.
@maksymdudyk1718
@maksymdudyk1718 3 жыл бұрын
Kyle is the best tech influencer in the universe.
@Chewbu
@Chewbu 3 жыл бұрын
DUDE The school I am with was trying to explain this and I was so LOST! I said screw this and came here and I understood everything by watching it ONCE!!! I spent hours on an assignment scratching my head like what the heck does any of this mean and why is the return the "clean up". NOW I KNOW.
@Chewbu
@Chewbu 3 жыл бұрын
I am promoting you from now on that $60 deal is seemingly the best deal I have seen in my mfing life. I'll be paying AS SOON AS I'm done with this course I'm in.
@numberoneBORON
@numberoneBORON 2 жыл бұрын
You have a gift man, I really understand when I watch your videos!
@DeepakSingh-sy4ws
@DeepakSingh-sy4ws 4 жыл бұрын
i have no words which can appreciate your work.
@heyamjoe
@heyamjoe 2 жыл бұрын
I always look forward to the intro tune, it's soothing.
@BionicPanda7
@BionicPanda7 Жыл бұрын
Great video man.
@fithamlakfikrie4657
@fithamlakfikrie4657 Жыл бұрын
Thank you very much 🙏, It was a very clear explanation with sufficient but short examples.
@SitaMbili
@SitaMbili 3 жыл бұрын
This video makes useEffect so clear and I feel like I finally understand it now thanks to you!
@marikabasagoitia6828
@marikabasagoitia6828 2 жыл бұрын
As usual, thank you so much for your explanations. By far the best resource for web development on KZbin!
@ThiagoVieira91
@ThiagoVieira91 4 жыл бұрын
Hey Kyle thank you for this new series. I've been a rough time trying to study steadily while working from during this quarantine. This new series got me back on track. Waiting for the next episode!
@mohdsameer8899
@mohdsameer8899 11 ай бұрын
What do you do now just curious 🧐
@AdamElMou
@AdamElMou 3 жыл бұрын
I never comment but wow. You're like a gift to the internet, thank u, rlly
@go_all_the_way
@go_all_the_way Жыл бұрын
you're a life saver and amazing teacher
@ryo736
@ryo736 3 жыл бұрын
Hi, I am a beginner of React and your videos are really helpful for me! Thank you a lot! And I wonder if you would be willing to make the automatic captions on? That will be friendlier to the foreign audience like me🙇‍♂️ Thanks for your amazing videos again.
@TheNsNZ
@TheNsNZ 2 жыл бұрын
Great teaching mate but one thing that would make it better in my opinion would be to slow down a bit and use more analogies as a lot of people find things easier to grasp this way. Could just be me though, from what I can see everyone loves these tutorials.
@coderite_
@coderite_ Жыл бұрын
Exactly. I think he's too fast
@dystopian_1
@dystopian_1 Жыл бұрын
Very nice, brother... Thank you!
@afiqk8543
@afiqk8543 10 ай бұрын
This man is awesome. Even his cat 10:32 understands what he is teaching 🐱
@Imran-Desk
@Imran-Desk 2 жыл бұрын
I've been banging my head to understand useEffect for like months, and in this video I just got it in a minute 😶
@ikhtiyorkhikmatov6316
@ikhtiyorkhikmatov6316 2 жыл бұрын
Best explanation, found exact answers about how does effect actually work
@SohamNag12321
@SohamNag12321 4 ай бұрын
You are the reason I know React! Thank you!
@cevatmorcicek9134
@cevatmorcicek9134 Жыл бұрын
Thank you so much!!The examples were quite easy to understand.I got it so well.I wish you the best!
@먼데이좋은데이
@먼데이좋은데이 2 жыл бұрын
You are a blessing to noob web developers like me.
@ahancho
@ahancho 2 жыл бұрын
unrelated comment but your hair looks incredible in terms of style, volume and shine
@chabbershaw
@chabbershaw 2 жыл бұрын
React18 is now changing all of this. You're now supposed to put your side-effects in the event handlers and useEffect is only used for external synchronization. 🤯
@michaelNXT1
@michaelNXT1 2 жыл бұрын
You're the best, I'm starting to learn React Native and I'm looking forward to have my questions answered by you!
@adityanjsg99
@adityanjsg99 2 жыл бұрын
Presentation Level, Ultra Pro Max!
@sammcalilly107
@sammcalilly107 2 жыл бұрын
this helped me learn how i've been improperly using hooks. thanks!
@GoddessofWarr
@GoddessofWarr 2 жыл бұрын
So clear... I was struggling with this concept, now it's ok, thank you very muck Kyle !
@SouradeepBasuTechsavvy
@SouradeepBasuTechsavvy 4 жыл бұрын
Man you literally are a god to me! I learn more from you than at University!
@frankenfishdom
@frankenfishdom Жыл бұрын
thanks for breaking this down so well, I finally understand what's going on!
@darentok8608
@darentok8608 2 жыл бұрын
Thank you for this. Finally understood useEffect and useState
@sambacarlson
@sambacarlson Жыл бұрын
You are a Genius man! 💯👌and you really really know how to explain. Thank you man
@mxolisingwenya5486
@mxolisingwenya5486 2 жыл бұрын
The best and clear explanation ever
@pranavp4122
@pranavp4122 2 жыл бұрын
Thank you Kyle...... Your video is very helpful for the beginners like us!
@shivam3839
@shivam3839 Жыл бұрын
nice explanation
@coltgar2465
@coltgar2465 4 жыл бұрын
You are my go to channel when I need to learn
@debanjansinha3750
@debanjansinha3750 3 жыл бұрын
man u are awesome the way u explain things in a simple manner really helps a lot for the people keep up doing the good stuff..
@MatthewPostrel
@MatthewPostrel Жыл бұрын
Much better explanation than my Udemy course... Thanks!
@woodyboy123
@woodyboy123 4 жыл бұрын
You are the best man. So quick and easy to understand when you teach it. Can't believe I've been putting off taking the time to learn hooks when all it would have taken was a 13 minutes with you👍🏼
@kal1nadam205
@kal1nadam205 Жыл бұрын
amazing explanation in such a short video, thank you!
@flowerofash4439
@flowerofash4439 2 жыл бұрын
God damn! this is like 10x easier to understand than react documentation
@sushi_lesushi
@sushi_lesushi 2 жыл бұрын
2 questions: starting from 4:47, why you have 2 "render" printed in your console, when you have 1 console.log("render") in your code? And at 5:00 when you changed your clicked button to "posts"- "resource type changed" vs "render" were printed. When you clicked second time in a row the "posts" button, "render" was printed again and "resource type changed" was not, which is understandable according to your explanations, but your subsequent clicks on "posts" did not trigger useSatet hook (if "render" was not printed). I understood why useEffect didn't work, but didn't understand why console.log("render") didn't work as well, although it rendered when you clicked "posts" 2 times in a row
@rohitchaudhry4355
@rohitchaudhry4355 3 жыл бұрын
Best explnation I have come across for the react hooks !!
@whathappenedthere592
@whathappenedthere592 Жыл бұрын
one of the best explanations ever...loved it
@lukas.webdev
@lukas.webdev Жыл бұрын
I agree! 😉
@rohansharma4844
@rohansharma4844 3 жыл бұрын
tired of posting thanku for this guy u really make web dev simplifuckinfied
@Mrinfinity02
@Mrinfinity02 3 жыл бұрын
best explanation on internet 👍👍
@axelgrind
@axelgrind Жыл бұрын
helpful vid, thanks!
@yasirupadmasiri3725
@yasirupadmasiri3725 3 жыл бұрын
This is most understandable I have ever seen.
@madsidification
@madsidification 2 жыл бұрын
Dude you explained is so easily, simply amazing man 🔥
@vnoommuy
@vnoommuy 4 жыл бұрын
Hey man, thanks for your amazing work. Have you ever considered streaming?
@WebDevSimplified
@WebDevSimplified 4 жыл бұрын
I've thought about it but really don't have the time to do so right now. I can barely squeeze in the videos I do make each week.
@anmolsharma433
@anmolsharma433 4 жыл бұрын
yo man hats off to you man you can break any complex topic into simple pieces love your vids man.
@shaybatman7108
@shaybatman7108 2 жыл бұрын
This is the best channel on youtube!
Learn useMemo In 10 Minutes
10:42
Web Dev Simplified
Рет қаралды 489 М.
Learn useState In 15 Minutes - React Hooks Explained
15:45
Web Dev Simplified
Рет қаралды 1,2 МЛН
Disrespect or Respect 💔❤️
00:27
Thiago Productions
Рет қаралды 42 МЛН
ТЫ В ДЕТСТВЕ КОГДА ВЫПАЛ ЗУБ😂#shorts
00:59
BATEK_OFFICIAL
Рет қаралды 4,3 МЛН
Top 6 React Hook Mistakes Beginners Make
21:18
Web Dev Simplified
Рет қаралды 580 М.
Beginner React.js Coding Interview (ft. Clément Mihailescu)
36:31
Ben Awad
Рет қаралды 2,2 МЛН
All useEffect Mistakes Every Junior React Developer Makes
22:23
Learn React Hooks: useEffect - Simply Explained!
14:07
Cosden Solutions
Рет қаралды 166 М.
Speed Up Your React Apps With Code Splitting
16:50
Web Dev Simplified
Рет қаралды 391 М.
Why Signals Are Better Than React Hooks
16:30
Web Dev Simplified
Рет қаралды 488 М.
How To Handle Permissions Like A Senior Dev
36:39
Web Dev Simplified
Рет қаралды 143 М.
Learn useImperativeHandle In 10 Minutes
9:34
Web Dev Simplified
Рет қаралды 69 М.