Learn JavaScript CALLBACKS in 7 minutes! 🤙

  Рет қаралды 76,109

Bro Code

Bro Code

Күн бұрын

Пікірлер: 88
@BroCodez
@BroCodez Жыл бұрын
// callback = a function that is passed as an argument // to another function. // used to handle asynchronous operations: // 1. Reading a file // 2. Network requests // 3. Interacting with databases // "Hey, when you're done, call this next." hello(goodbye); function hello(callback){ console.log("Hello!"); callback(); } function goodbye(){ console.log("Goodbye!"); }
@Blitz61wasd
@Blitz61wasd Жыл бұрын
@BroCodez Django course please
@Blitz61wasd
@Blitz61wasd Жыл бұрын
Bro i subscribed and liked can you make django course
@-_SleepAndEat_-
@-_SleepAndEat_- 8 ай бұрын
Bro can you do Kali Linux ?
@1992daven
@1992daven Жыл бұрын
I love the way you explain. Those other youtubers had me lost.
@thatlastborn
@thatlastborn 10 ай бұрын
Right!!!
@jimmyhaotran123
@jimmyhaotran123 7 ай бұрын
exactly always got me lost when other youtubers keep on repeating something like, we put another function inside a function as a paramether and in the function block we call back to the function a callback function, that is why it is called a callback function. And then they continue on giving an example of either a function with another function as parameter, or array functions console logging the elements when iterating through the elements. Like why would console log be a callback function, they never explain, This video explains everything to me. Thanks!!!
@isaiahaguilera7973
@isaiahaguilera7973 Жыл бұрын
Bro, this was the easiest explanation I've ever seen. Thank you!
@a1m4thah3d
@a1m4thah3d 3 ай бұрын
Anytime I'm learning something new and struggling, I watch a BroCode video and walk away totally getting it. I LOVE how everything is clear and concise and not a lot of needless rambling.
@thatlastborn
@thatlastborn 10 ай бұрын
Honestly callbacks really left me confused. This is by far the best explanation I’ve watched. Tysm ❤
@tayangantengahmalam2480
@tayangantengahmalam2480 10 ай бұрын
True
@masterwitcher317
@masterwitcher317 9 ай бұрын
I love how you explain complex topics like this. You really helps me a lot.
@vallunacoder.wecodetogether
@vallunacoder.wecodetogether Жыл бұрын
Fell like I'm finally understanding js. Thanks BRO! Greetings from Colombia!
@saichaithrik7134
@saichaithrik7134 9 ай бұрын
one of the greatest explanation i have ever seen
@r3dwulf3
@r3dwulf3 8 ай бұрын
Finally, I understood this. The concept was very confusing when others tried to explain it, and this video made it very simple to understand. Thank you for breaking it down.
@3lirez
@3lirez 8 ай бұрын
You explained this in the simplest way possible bro! Now I love the “Bro Code” Channel!
@mohitanand5646
@mohitanand5646 6 ай бұрын
Thank you for those example codes. Those really help with understanding the concept in-and-out of the box.
@piotrmazgaj
@piotrmazgaj 5 ай бұрын
This is my seal. I have watched the entire video, understood it, and I can explain it in my own words, thus I have gained knowledge. This is my seal.
@yashashvi5048
@yashashvi5048 29 күн бұрын
Man ur the goat no one explains like u do many thanks
@SpeaksYourWord
@SpeaksYourWord 6 ай бұрын
The only freaking madlad that never disappoints. Only one.
@kunalpal6647
@kunalpal6647 Жыл бұрын
Such a beautiful explanation, Bro...earned a sub!!
@KarthikRajaKasirajan
@KarthikRajaKasirajan Ай бұрын
Amazing, pretty simple explanation. Good stuff
@anitamurphy2323
@anitamurphy2323 Жыл бұрын
And i finally understand. Greetings from Ireland x
@nononono-pw1tk
@nononono-pw1tk 2 ай бұрын
the profile pic is on spot. you're a giga chad for this vid, i needed someone else to explain this to me cuz i could not understand it from my teacher, thx.
@usman_acts
@usman_acts 11 ай бұрын
@BroCodez : an impressive way to teach... A lot to learn in just 7 minutes Love from Lahore, Pakistan
@liamrichardson62
@liamrichardson62 5 ай бұрын
THANK YOU SO MUCH😭. I really needed this⭐
@jatinjain1082
@jatinjain1082 2 ай бұрын
Amazing Explanation . Thank you so much
@rameenana
@rameenana 8 ай бұрын
This was very helpful mate. Thanks! Appreciate your work.
@khalidelgazzar
@khalidelgazzar 5 күн бұрын
Great explanation. Thanks 😊
@ФёдорСёмочкин
@ФёдорСёмочкин 8 ай бұрын
Your videos helped me understand JS although i have already watched a lot of videos on JS. Thanks Bro!
@ashutoshsingh583
@ashutoshsingh583 2 ай бұрын
best video on func callback thks man.
@sarabadr1376
@sarabadr1376 11 ай бұрын
Thank you so much for making it so simple and understandable ❤
@juancruzsantillanmenendez4254
@juancruzsantillanmenendez4254 Жыл бұрын
You're the best, love from argentina!!
@Eldorbek-Yokubjonov
@Eldorbek-Yokubjonov 9 ай бұрын
the most simple and human understandable explanation thanks bro code
@suwaddy1566
@suwaddy1566 8 ай бұрын
Thanks for explaining callback function.
@FindingFocus
@FindingFocus 8 ай бұрын
this was the video that finally helped this click with me. thank you!!!
@Saquib-r4n
@Saquib-r4n 5 ай бұрын
bro i am not understanding the callback since yesterday after ur explanation i m going to subscribe u ASAP!!
@CHANDRASHEKARRAHCS
@CHANDRASHEKARRAHCS 8 ай бұрын
liked the way u explained things so simple and clear keep posting 💌
@jauerboo6526
@jauerboo6526 11 ай бұрын
good explanation!
@flowdesigner
@flowdesigner 2 ай бұрын
Dang! That was a good explanation!!!
@zeelrana3369
@zeelrana3369 5 ай бұрын
Great explanation 👍
@vedantrawat4064
@vedantrawat4064 8 ай бұрын
Thank You so much before this video I was not able to understand this concept , I am now able to understand better .... Pls provide more such informative videos like this... ❤
@sridhararivazhagan1323
@sridhararivazhagan1323 5 ай бұрын
Thanks for this wonderful explanations I understand this in easy way thanks bro🎉
@ColeHartman1
@ColeHartman1 7 ай бұрын
One thing I believe could have been clarified is that callback() does not actually WAIT for the line of code above it to be done. If the line above is asynch, it will call callback() first.
@zine-el-abidine
@zine-el-abidine 3 ай бұрын
i got it, thank you your the best !
@elzosantos1253
@elzosantos1253 10 ай бұрын
Hi, okay, I want to congratulate you for this incredible work, where you share your knowledge. I want to ask a question about how I render the results of the code in the console, so I know how to do it with HTML
@gloryanoliefo
@gloryanoliefo 8 ай бұрын
Add the relevant script tag in your HTML file and set the src to your javascript file, then go live from your vs code, then navigate to your console in your browser, you will see the changes rendered as you code.
@andrews13
@andrews13 28 күн бұрын
You are the best!
@hasanatahmadzai9079
@hasanatahmadzai9079 5 ай бұрын
Truely you're the best.
@brijeshkumarchavda
@brijeshkumarchavda 4 ай бұрын
Thank you ❤
@jadad7296
@jadad7296 Жыл бұрын
cool
@johnwayne8059
@johnwayne8059 8 ай бұрын
What do you know about promises? Would be interesting to see something about it!
@johnnyenglish3867
@johnnyenglish3867 Жыл бұрын
legend
@otisprogramming2437
@otisprogramming2437 Ай бұрын
Simple explanation, however I found the example of setTimeout to be open to misinterpretation or a little misleading. If we invoke the callback goodbye after a setTimeout function, the callback would still be logged first. I think due to setTimeout using a callback itself which interacts with the event loop and event queue.
@girishph.9970
@girishph.9970 10 ай бұрын
if you had explained it using the setTimeout function itself it would have been much easier to understand i think , but thankyou.
@rx808
@rx808 Жыл бұрын
legend!!
@ikki_nikoo
@ikki_nikoo 5 ай бұрын
randomComment() // LOVE YOU BRO CODE THANKS YOU!
@mohammadalsallal7977
@mohammadalsallal7977 9 ай бұрын
this guy is insane
@deeplife9654
@deeplife9654 22 күн бұрын
we need call-back mechanism to ensure that one function is called after another function sequentially ?
@kathikr9360
@kathikr9360 9 ай бұрын
thank you
@ArthurWM9
@ArthurWM9 Жыл бұрын
So what's the difference between using a function as callback and just calling the function from inside the one which will take some time to finish? Wouldn't this accomplish the same thing? Thanks for the video!
@jesusjosemarthalaborin1014
@jesusjosemarthalaborin1014 Жыл бұрын
I have the same question or is that even a callback function too?
@Shubh_R_M
@Shubh_R_M Жыл бұрын
Both works same in most of the cases but there are some points to be consider: 1 ) callback program flow is more controllable 2 ) asynchronous operation execution for e.g in video goodbye is executing later if we write normal hello function and call goodbye function in hello function and after calling goodbye function write another code then if goodbye function takes time to execute then other code after goodbye call will also has time delay . which is not happen in call back case . HOPE THIS HELP : )
@abdoun8214
@abdoun8214 10 ай бұрын
still confused.
@alirezafarokhzadeh
@alirezafarokhzadeh 13 күн бұрын
hi, and thanks for your videoes, I have a question: why the folowing code didn't work correctly? and show "two" befor "one" one(two); function one(callback) { setTimeout(() => { console.log("One!"); }, 4000); callback(); } function two() { console.log("Two!"); }
@Blitz61wasd
@Blitz61wasd Жыл бұрын
Django course please
@shauryasingh63
@shauryasingh63 9 ай бұрын
Thanks Bro!!
@7calculus
@7calculus 7 ай бұрын
But if you use the setTimeout, then even with callback, bye is displayed first.....what's happening here?
@LaughThyself
@LaughThyself 3 ай бұрын
i think setTimeout will run only after callback is done, this is 3 mo idk if it helps still
@Ajinkkyaa_naik
@Ajinkkyaa_naik 17 күн бұрын
Been banging my head over this since a week. LIke I understand the whole concept but always failing to put it into use. the creation is not coming to me automatically and organically. Any other ways I can improve writing callbacks? the difficulty I am having is the writing the whole thing in a correct order. I have seen many coders write this differently.
@spencersedano
@spencersedano 7 ай бұрын
Thank you bro code
@jay70p
@jay70p 21 күн бұрын
is it AJAX ?
@SadidIslam27
@SadidIslam27 Жыл бұрын
best
@guilhermemanoel116
@guilhermemanoel116 6 ай бұрын
Goat!
@sportsknowledge92
@sportsknowledge92 11 ай бұрын
Hi bro code please make small small project using function object array
@coding_stuff_uz
@coding_stuff_uz Жыл бұрын
Bro Django please 🥲
@hungry_khid1007
@hungry_khid1007 Жыл бұрын
What is that , is it good?
@coding_stuff_uz
@coding_stuff_uz Жыл бұрын
@@hungry_khid1007 Yes, of course. It looks like python
@albertt755
@albertt755 5 ай бұрын
This callback function seems complicated.
@raghabpandit2610
@raghabpandit2610 2 ай бұрын
if the world ever has international code organization type shi Bro Code should be the president of it
@tabaeimohamedamine9243
@tabaeimohamedamine9243 3 ай бұрын
@lorieldesamito3998
@lorieldesamito3998 8 ай бұрын
chad
@Theoublal
@Theoublal Жыл бұрын
Bro react
@saliouseck7715
@saliouseck7715 Жыл бұрын
HI BROCODE THANKS FOR THE VIDEOS WHERE CAN WE CONTACT YOU ?
@nahidhasan5607
@nahidhasan5607 3 ай бұрын
nice explanation!
@divyaanshuagrawal3383
@divyaanshuagrawal3383 6 ай бұрын
Thanks Bro!
JavaScript forEach() method in 8 minutes! ➿
8:02
Bro Code
Рет қаралды 44 М.
Async JavaScript & Callback Functions -- Tutorial for Beginners
24:21
Cheerleader Transformation That Left Everyone Speechless! #shorts
00:27
Fabiosa Best Lifehacks
Рет қаралды 16 МЛН
When you have a very capricious child 😂😘👍
00:16
Like Asiya
Рет қаралды 18 МЛН
JavaScript FUNCTIONS are easy! 📞
12:14
Bro Code
Рет қаралды 53 М.
JS Promises in 4 Minutes
3:51
CodeNexus
Рет қаралды 2,2 М.
My 10 “Clean” Code Principles (Start These Now)
15:12
Conner Ardman
Рет қаралды 316 М.
10 Important Python Concepts In 20 Minutes
18:49
Indently
Рет қаралды 441 М.
Callbacks in JavaScript Explained!
14:03
Code with Ania Kubów
Рет қаралды 155 М.
5 Uncommon Python Features I Love
15:09
Indently
Рет қаралды 174 М.
What are JavaScript PROMISES? 🤞
12:37
Bro Code
Рет қаралды 88 М.