EVENT.TARGET, in JavaScript, Simplified

  Рет қаралды 21,488

Deeecode The Web

Deeecode The Web

Жыл бұрын

When handling events, an event object, containing all the information about the event, is passed to the callback function you provide. One major property of this event object, is the target property, which contains information about the element that received the event.
In this video, I use examples to explain this property and show why its relevant.
Useful links:
- querySelector explained: • HOW TO SELECT DOM ELEM...
- Event Bubbling: • Event Bubbling in Java...
- Event Delegation: • Event Delegation in Ja...
- Object Destructuring: • Object Destructuring S...
Check out my JavaScript Simplified playlist where I simplify different concepts in JavaScript: • JavaScript Simplified
_____
Subscribe to My Channel: bit.ly/deeecode
_____
🌟 About Me:
Dillion Megida, creator of DEEECODE, is a Software Engineer, Developer Advocate and a Content Creator passionate about simplifying topics around Tech via articles and videos.
_____
⚡️ Connect with me:
- Personal youtube: / dillionmegida
- Personal website: dillionmegida.com/
- Twitter: / iamdillion
- Instagram: / deeecode
- LinkedIn: / dillionmegida
- GitHub: github.com/dillionmegida
_____
#deeecode

Пікірлер: 108
@deeecode
@deeecode Жыл бұрын
Check out my JavaScript Simplified playlist where I simplify different concepts in JavaScript: kzfaq.info/sun/PLLdz3KlabJv0TBKCbF9aSxIpCxsLiFhEv
@hybs9473
@hybs9473 Жыл бұрын
Thank you for doing this my man Dee! I appreciate it very much. Looking forward for more tutorials from you.
@deeecode
@deeecode Жыл бұрын
You're welcome 🙏🏾
@archangel4894
@archangel4894 Жыл бұрын
Bro, your tutorial is much easier to understand than other tutorial I previously watched. Thanks to you!
@deeecode
@deeecode Жыл бұрын
I'm so so glad to hear this! Thanks for the feedback, and I'm glad you found it easier.
@destinyifeanyichilaka6434
@destinyifeanyichilaka6434 3 ай бұрын
This really made me understand more about event.target
@explorewithpraveen
@explorewithpraveen 2 ай бұрын
Thanks, there is only your video in you tube who explain the use of target deeply, again thanks
@deeecode
@deeecode 2 ай бұрын
Glad it was helpful! You're welcome :)
@mariopizzaro
@mariopizzaro Жыл бұрын
Hi mate, you can really explain stuff in a very easy-to-understand way, thank you ! Greetings from N.Ireland
@deeecode
@deeecode Жыл бұрын
Heyyy...Greetings from the Netherlands. Thank you so much for the kind feedback. I'm so glad you enjoyed this
@Kivencito
@Kivencito Жыл бұрын
Brother... I'm starting in JS and I had this problem with the onload method... after 2 days trying, this was my solution. THANKS!
@deeecode
@deeecode Жыл бұрын
I'm so so so glad to hear this feedback. You're welcome. Feel free to share topics you'd like me to make videos about.
@marypaul9627
@marypaul9627 Ай бұрын
Elements receives different forms of events in the DOM! That opening line explains it all thank you, have subscribed!
@deeecode
@deeecode 25 күн бұрын
I’m so glad to hear ✨
@jamblob3208
@jamblob3208 3 ай бұрын
I had done this a few way before but remembering and doing it differently shows problems as well as unexpected solutions. This was the inspiration, bubbling along next to it. yipety doo.
@CLeovison
@CLeovison 11 ай бұрын
This is the kind of tutorial that i need. Well explained. Thank you so much maaan!
@deeecode
@deeecode 10 ай бұрын
You're welcome! So glad to hear
@pauledukere8353
@pauledukere8353 4 ай бұрын
Wow.. nice explaination.. I have definitely learnt something
@AvidAfrican
@AvidAfrican 9 ай бұрын
I swear this guy is Nigerian! And you explain it better and what happened after calling the function i just subscribed to your channel as a fellow Nigerian! Bro teach us more.... break it down bro!
@deeecode
@deeecode 8 ай бұрын
Hahah thank you so much and welcome!
@tanoypaul
@tanoypaul 2 ай бұрын
Thanks teacher , I was struggling from this exact thing ! You made it much more easier for me
@deeecode
@deeecode 2 ай бұрын
You're very welcome! I'm so so glad to help
@JhonLogix
@JhonLogix Жыл бұрын
Very well explained! Thanks for sharing this with us. Keep it up champ!
@deeecode
@deeecode Жыл бұрын
Glad you liked it! You're welcome
@isaacaninta6551
@isaacaninta6551 4 ай бұрын
Really love this guy ❤❤❤❤.
@codingsenpai
@codingsenpai 10 ай бұрын
Thank you, man, so useful !👏
@deeecode
@deeecode 6 ай бұрын
Glad to hear :)
@aprendahebraicocomabiblia1090
@aprendahebraicocomabiblia1090 3 ай бұрын
Simply awesome!
@deeecode
@deeecode 14 күн бұрын
Thank you! Cheers!
@noobme1068
@noobme1068 Жыл бұрын
well explained.Thank you!
@deeecode
@deeecode Жыл бұрын
You're welcome!
@chocolyte1950
@chocolyte1950 9 ай бұрын
Thnx a lot sir love from india🇮🇳🇮🇳
@deeecode
@deeecode 8 ай бұрын
You're very welcome!
@yaniquedickson8276
@yaniquedickson8276 12 күн бұрын
thank you!
@caioluna9229
@caioluna9229 Жыл бұрын
Thank you! My college teacher doesn't explained to me that, only passed the answer, and I was struggling to understand by myself how and why this works.
@deeecode
@deeecode Жыл бұрын
I'm so glad to hear that this was helpful!
@famero_xo
@famero_xo 15 күн бұрын
Really helpful, thanks and well-done 🎉❤
@deeecode
@deeecode 14 күн бұрын
Glad you enjoyed it!
@davidezih3510
@davidezih3510 Жыл бұрын
Bro!! You're good! love the explanations...
@deeecode
@deeecode Жыл бұрын
Thank you so much for this feedback. I'm glad you love it
@nagarjuna5557
@nagarjuna5557 7 ай бұрын
Wow, bro it's easy to understand thank you
@deeecode
@deeecode 7 ай бұрын
I'm so glad to hear this...you're welcome!
@dinasalah855
@dinasalah855 Жыл бұрын
Wow that is super amazing …thanx🙏
@deeecode
@deeecode Жыл бұрын
Glad you like it. You're welcome!
@louiebridges174
@louiebridges174 Ай бұрын
Thank you so much!!
@deeecode
@deeecode 25 күн бұрын
You’re welcome :)
@marielfigueroacolmenares1869
@marielfigueroacolmenares1869 Жыл бұрын
Clarísimo, gracias!!
@deeecode
@deeecode Жыл бұрын
You're welcome
@nabeelkhan-dp2fc
@nabeelkhan-dp2fc Жыл бұрын
nicely explained buddy...thanks
@deeecode
@deeecode Жыл бұрын
glad you found it so
@imanariyobaptiste8177
@imanariyobaptiste8177 10 ай бұрын
practical explained bro keep it up
@deeecode
@deeecode 6 ай бұрын
Thank youuu
@iamnottech8918
@iamnottech8918 2 ай бұрын
I really thought the same but I was doubtful but now I am sure
@deeecode
@deeecode 2 ай бұрын
You're very welcome!
@cescr3821
@cescr3821 Жыл бұрын
came here for javascript tutorial, stayed for the accent, but no joke the video is great thank you.
@deeecode
@deeecode Жыл бұрын
Haha glad you liked my accent. and thanks for the feedback regarding the video
@avalonstudio2753
@avalonstudio2753 Жыл бұрын
@@deeecode naija accent i am gussing, leaning javascript too, thank for the video by the way
@Petersonbabs
@Petersonbabs 8 ай бұрын
You're good boss. Would like to see a video of how you create content
@deeecode
@deeecode 6 ай бұрын
Coming back to this comment, I'll make a video on this to wrap up the year :) Will let you know when published
@Petersonbabs
@Petersonbabs 6 ай бұрын
@@deeecode is it out now boss. Really would love to such content.. How you come up with ideas, plan your content, film, edit.. advice Would really help...
@deeecode
@deeecode 6 ай бұрын
@@Petersonbabs Hi...so sorry I couldn't publish it before the new year like I said I would. But here's the video live now: kzfaq.info/get/bejne/l5limcWitbTNomg.html
@Petersonbabs
@Petersonbabs 6 ай бұрын
@@deeecode thank you
@fabrice9848
@fabrice9848 11 ай бұрын
Thank you.
@deeecode
@deeecode 10 ай бұрын
You're welcome!
@ormtosteson9553
@ormtosteson9553 3 ай бұрын
Nice explanation and examples
@archonarchon6613
@archonarchon6613 2 ай бұрын
wow nice explanation👍👍👍
@deeecode
@deeecode 2 ай бұрын
I'm so glad you enjoyed it ;)
@jamblob3208
@jamblob3208 3 ай бұрын
Tricky stuff. Syntax n all that on top of the why should I need it. I thought this was revision of a hard day but the same errors for me showing how hard it is to know how to alter things just slightly.
@w23music17
@w23music17 Жыл бұрын
Thanks bro..
@deeecode
@deeecode Жыл бұрын
You're welcome :)
@ricko13
@ricko13 Жыл бұрын
nice explanation bro
@deeecode
@deeecode Жыл бұрын
Glad you liked it
@MatheusPereira-nn9dj
@MatheusPereira-nn9dj Жыл бұрын
Awsome content 🔥
@deeecode
@deeecode Жыл бұрын
You're welcome :)
@mnnw148
@mnnw148 Жыл бұрын
Great 😊
@deeecode
@deeecode 6 ай бұрын
You're welcome
@relaxsongwithjeff1263
@relaxsongwithjeff1263 9 ай бұрын
Hello I'm having an error with this. Could you explain it to me why? I'm getting the name Id and assigning it to a variable here. Const nameId = document.getElementById("nameId"); And then i have an event listener that listen to the assigned element above. nameId.addEventListener("keyup", () => { function(); // this function execute when this event is made }); Now I'm having this (Uncaught TypeError: nameId is null) whenever I'm on a different page on my web. But when I'm on the where this code is being used I'm not having that error. What i did is i wrap the event listener to an if statement checking if the nameId is not null then execute the event. Is there any other way i could do this?
@zachmathias26
@zachmathias26 Жыл бұрын
any reason why you used query selector opposed to getElementById?
@deeecode
@deeecode Жыл бұрын
there was no specific reason. i've found myself liking querySelector when I want to do any element query (from classes to ids to attributes), and I also wanted to show in this video that there are multiple ways you can get elements from the DOM
@enibondarenko1233
@enibondarenko1233 Жыл бұрын
super helpful
@deeecode
@deeecode Жыл бұрын
Glad it helped!
@BSITVinluanEner
@BSITVinluanEner Жыл бұрын
Thaks bro
@deeecode
@deeecode Жыл бұрын
you're welcome
@bananabread6758
@bananabread6758 Жыл бұрын
very good
@deeecode
@deeecode Жыл бұрын
Thank you! Cheers!
@therobber
@therobber 10 ай бұрын
Amazing
@deeecode
@deeecode 10 ай бұрын
Thank you! Cheers!
@binhors6854
@binhors6854 Жыл бұрын
THANK YOU MAN< BRASIL LOVES YOU
@deeecode
@deeecode Жыл бұрын
thank you so much 🥹
@vikitalk
@vikitalk 8 ай бұрын
thanks sir
@deeecode
@deeecode 8 ай бұрын
Most welcome
@user-ko8cl4dd9w
@user-ko8cl4dd9w 11 ай бұрын
very nice
@deeecode
@deeecode 6 ай бұрын
you're welcome
@TEJASSADADE
@TEJASSADADE Жыл бұрын
love from india
@deeecode
@deeecode Жыл бұрын
Thank youuuuuuuu!
@Dee_Dev
@Dee_Dev 5 ай бұрын
Please 🙏 make a video on html data attributes and dataset methods please @deeecode
@devSackey
@devSackey 2 ай бұрын
Lucid Explanation
@hexgrade177
@hexgrade177 Жыл бұрын
W tutorial
@deeecode
@deeecode Жыл бұрын
Nice to know. Thank you
@TheDon__dev
@TheDon__dev 8 ай бұрын
Explanation is clean but I’m still confused 🥲
@deeecode
@deeecode 8 ай бұрын
Hi, In what way are you confused? 🤔
3 Ways to Merge Arrays, in JavaScript
6:09
Deeecode The Web
Рет қаралды 780
Event Bubbling in JavaScript, Simplified
5:00
Deeecode The Web
Рет қаралды 14 М.
МАМА И STANDOFF 2 😳 !FAKE GUN! #shorts
00:34
INNA SERG
Рет қаралды 4,2 МЛН
Osman Kalyoncu Sonu Üzücü Saddest Videos Dream Engine 170 #shorts
00:27
Learn JSON in 10 Minutes
12:00
Web Dev Simplified
Рет қаралды 3,1 МЛН
Do you know the difference between target vs. currentTarget?
8:25
Coding in Public
Рет қаралды 5 М.
Event Delegation in JavaScript, Simplified
8:46
Deeecode The Web
Рет қаралды 11 М.
JS Event target versus currentTarget
3:59
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 48 М.
Javascript Promises vs Async Await EXPLAINED (in 5 minutes)
5:50
Roberts Dev Talk
Рет қаралды 554 М.
Learn JavaScript Hoisting In 5 Minutes
5:40
Web Dev Simplified
Рет қаралды 121 М.
Learn JavaScript DOM Traversal In 15 Minutes
14:44
Web Dev Simplified
Рет қаралды 221 М.
Hisense Official Flagship Store Hisense is the champion What is going on?
0:11
Special Effects Funny 44
Рет қаралды 2,4 МЛН
#miniphone
0:16
Miniphone
Рет қаралды 3,7 МЛН