Learn DOM Manipulation In 18 Minutes

Поділитися
Вставка
  • Опубліковано 21 вер 2024

КОМЕНТАРІ • 545

  • @pixelfixer_
    @pixelfixer_ 3 роки тому +1221

    I know it's not a big thing or anything, but thank you for timestamping your videos. It's so incredibly useful, and not enough content creators take the time to do that

    • @WebDevSimplified
      @WebDevSimplified  3 роки тому +260

      I'm glad you appreciate it. I have been trying to do it on all my new videos.

    • @oscarleon3008
      @oscarleon3008 3 роки тому +18

      @@WebDevSimplified Thank you for doing it, I always love it when someone in the comments does it for the longer videos. But it's even really cool that you take the time to do that yourself. Thanks for all the videos! I'm learning a ton from your channel.

    • @009a2
      @009a2 3 роки тому +15

      Totally agree. I would add to that, that the times times may not be useful the first time you watch the video, but they are super useful on the second watch when you try to reference something :-)

    • @RandomInternetIdot
      @RandomInternetIdot 3 роки тому +4

      Yeah some times I’m watching some programming video and I’m looking for some part of the video, but then I realize they didn’t take the time to put time stamps and I have to spend i while just looking for that part.

    • @randy918
      @randy918 2 роки тому +1

      Thanks for all the timestamping. I rely on it, never ignore it.

  • @freshpootube
    @freshpootube 3 роки тому +315

    I love how organised this guy is. Prepares chapters in his videos, provides links. So valuable.

    • @nischalbista6436
      @nischalbista6436 2 роки тому

      @homo sexual feminine male whistleblower confesion how do you know ?

    • @carguy-xv2cl
      @carguy-xv2cl 2 роки тому +5

      Even prepares his hair with gel.

    • @chadgregory9037
      @chadgregory9037 2 роки тому

      It's like if Zach Morrison was actually a responsible smart person

    • @thequantum-plator
      @thequantum-plator Рік тому

      @homosexual feminine biological male sexual slut 3 s t f u bot

  • @TruthSeekerClub
    @TruthSeekerClub 3 роки тому +110

    You know why I choose you always to review topics or see your tutorial before I learn new technology?
    1. Very simple.
    2. Clear.
    3. Very direct.
    4. Detailed.
    6. Cover a lot.
    7. You cover important things.
    8. Organized.
    9. I can have excellent understanding what is this technology all about. In general.

  • @caneroncel
    @caneroncel 2 роки тому +120

    As a 37 years old front-end developer I want to say that you are making a great job. You are very calm, your tone is cool and looks like you are know what are you doing :)
    World is a better place because of people like you. Keep going and share your knowledge bro.

    • @aymenob2484
      @aymenob2484 2 роки тому +2

      Indeed i like the quality of his videos very helpful

  • @younessbouhjar9576
    @younessbouhjar9576 3 роки тому +16

    A quick tip:
    in case you want to delete multiple elements in a div for example.
    document.getElementsByClassName('class-name') delivers a nodeList.that means you'll get an error if you used the remove() method.
    instead change style.display for all nodes by looping through the list for example:
    var div= document.getElementsByClassName('class-name');
    for (var i=0;i

    • @xXYourShadowDaniXx
      @xXYourShadowDaniXx 2 роки тому +4

      Or you can do it the correct way for deleting and loop through the NodeList and run remove() per element?
      let div=document.getElementsByClassName("test");
      Array.from(div).forEach((elem)=>{
      elem.remove();
      });

  • @tolgaacar1296
    @tolgaacar1296 3 роки тому +16

    I recommend you to import your js files after the tags in html files. Because The script can begin executing before the DOM is fully loaded. Then null property errors will occur.

  • @amit-jx5lh
    @amit-jx5lh 2 місяці тому +3

    As a professional, senior Web developer, I can guarantee that this guys has done a great job by making this video.
    Hats off to you man.❤❤

    • @乃卂卂-p3c
      @乃卂卂-p3c 17 днів тому

      i have a doubt, can i become a self taught web dev?

  • @RedBeardRetroTech
    @RedBeardRetroTech 3 роки тому +32

    I've been watching these videos to study, they're very straightforward and make so much more sense compared to my professors. I appreciate you making these videos

  • @terenceroberts5240
    @terenceroberts5240 3 роки тому +16

    Yes, going to start donating to this guy. He is an asset.

  • @BigSmoke-r9w
    @BigSmoke-r9w 6 місяців тому +2

    OMG this guy helped me alot especially with difficult topics of CSS and Javascript! He explains everything so well! He's basically my mentor without him knowing it.

  • @Nobody10150
    @Nobody10150 3 роки тому +8

    your calm voice while explaining is making the info float easily in my brain.. a lot of thanks!

  • @sankaranarayanan7847
    @sankaranarayanan7847 3 роки тому +19

    Was searching for dom related stuff and here it is

    • @elpolodiablo5486
      @elpolodiablo5486 3 роки тому +2

      Typical UA-cam comment

    • @edwingarcia5043
      @edwingarcia5043 3 роки тому +1

      Traversy Media has a nice crash course for DOM manupulation, I did learn a lot, of course You need to practice.

    • @edwingarcia5043
      @edwingarcia5043 3 роки тому

      @@elpolodiablo5486 wdym ?

    • @amongdoomers9464
      @amongdoomers9464 3 роки тому

      @@elpolodiablo5486 😂😂💯

  • @spondoolie6450
    @spondoolie6450 2 роки тому +1

    I've been on my JavaScript journey for about 1.5 months. Once I learned about the DOM everything now seems to make sense, where as before it was literally a guessing game on which methods to use to make things happen. This video is perfect for someone like me that needs a quick-start (sorry, I mean "quickStart") reference where I can have a short video that neatly explains all the methods I'm going to use > 90% of the time.
    Kyle is the man.

    • @xXYourShadowDaniXx
      @xXYourShadowDaniXx 2 роки тому +1

      Yes this video is one of the few that I would suggest to new JS devs, so they can learn actual Vanilla JS properly. Then once you can confidently make sites and tools with Vanilla JS you should try graduating to Vue / React / Angular.

  • @patricklemmer9902
    @patricklemmer9902 2 роки тому +1

    Just worked through this and another video about DOM traversal. I am extremely confident working with the DOM now, which wasn't the case 48hrs ago. Thank you so much for your clear instructions and on point explanations! Incredible value!

  • @Misfittykitty
    @Misfittykitty 2 роки тому +5

    Thank you for your time and effort making this video. I have been banging my head against a wall for HOURS trying to understand this, and you have made it crystal clear. I will pay it forward one day--and wish you all the best. Thanks again for your kindness in teaching this (and so well!!) :) :)

  • @jimhalpert9803
    @jimhalpert9803 3 роки тому +1

    Glad you talked about the security flaws of element.innerHTML. More people need to know how dangerous it can be if you let user put custom raw html into the page.

  • @InsipidTawfiiq
    @InsipidTawfiiq 4 місяці тому

    Your tone is very calm and soothing

  • @TheCodingOdyssey
    @TheCodingOdyssey 3 роки тому +181

    You can hear semi-colon singing ' Wish I was here' in the background' :D

    • @nabilhaouam8497
      @nabilhaouam8497 3 роки тому +7

      😅😅😂, he’s a legend though

    • @TheCodingOdyssey
      @TheCodingOdyssey 3 роки тому +5

      @@nabilhaouam8497 ha ha thats why there are songs singing in the background

    • @johnyepthomi892
      @johnyepthomi892 3 роки тому +2

      i get ocd. I make sure to use it since working with different launguages it makes it easier.

    • @fazlerabbi3093
      @fazlerabbi3093 3 роки тому +2

      And the JS shouting "I am too smart to live without you".

    • @hikari1690
      @hikari1690 3 роки тому

      I hear ;_; saying “I’m not needed anymore”

  • @NewDayMedia.
    @NewDayMedia. Рік тому

    Kyle bro please consider teaching full time . last few months i watched thousands of tutorials i swear you have a better way of making me understand things than anyone else.

  • @seanflood3987
    @seanflood3987 2 роки тому +5

    Props for being so well spoken and organized. You do a really good job at taking a concept and explaining it in a user friendly way. A lot of courses these days don't explain the "why" enough when teaching. Good job dude great content!

  • @hamzahahmad1670
    @hamzahahmad1670 3 роки тому +4

    Really great work . There aren't many proper DOM manipulation crash courses on youtube, so your efforts are very much appreciated. I know this is a very common thing to say on videos like these, but I actually opened youtube right now to search for a DOM manipulation crash course, so seeing this was a welcome surprise.

  • @yashmodi2432
    @yashmodi2432 Рік тому +2

    Thank you so much..Your content is very much precise and to the point and better than 2 hrs of video that other creators are making to explain this simple thing

  • @samip4sure
    @samip4sure 3 роки тому +3

    I've been doing too much React and NodeJS, I was looking for DOM refresher. Great Stuff !

    • @TheCodingOdyssey
      @TheCodingOdyssey 3 роки тому +1

      This is true, when I got into coding I started working directly in React and didn't do that much dom manipulation, only in some small personal projects

    • @TesterAnimal1
      @TesterAnimal1 3 роки тому

      HTML authors will always need software engineers.

  • @aatish4697
    @aatish4697 2 роки тому +4

    Sir, you've helped me a lot. DOM manipulation is the only thing that I've always struggled in HTML JS because I use React more than Vanilla JS. So thanks a lot.

    • @hnknd
      @hnknd Рік тому

      where exactly do you use vanilla JS. Asking since you already work with a framework?

    • @aatish4697
      @aatish4697 Рік тому +1

      @@hnknd When I was working for ClerksWell, it's a company based out of London and we still made all Web Projects using HTML, CSS, JS and JQuery

    • @hnknd
      @hnknd Рік тому

      @@aatish4697 oh okay. I use html css and js for my projects too due to some restrictions in the platform We're working on. I'm a rookie in the field and was thinking of expanding my skillset

  • @cleansermacaroni9892
    @cleansermacaroni9892 2 роки тому +1

    I have done a couple of frontend courses, and I didn't have any trouble with the content, but this is the first video that has made perfect sense of it all. Wow. Really nice. Thanks!

  • @Soap_js
    @Soap_js 3 роки тому +152

    00:00​ - Introduction
    01:01​ - Adding Elements
    02:58​ - Creating Elements
    04:04​ - Modifying Element Text
    07:30​ - Modifying Element HTML
    10:22​ - Removing Elements
    11:54​ - Modifying Element Attributes
    14:11​ - Modifying Data Attributes
    16:13​ - Modifying Element Classes
    17:40​ - Modifying Element Style

  • @স্বচ্ছনিরবতা

    I just started learning DOM manipulation and here you are with the right video at the right time,
    Thank you much Kyle

  • @zakariakachani9143
    @zakariakachani9143 3 роки тому +16

    Love this man he explain so well and act like a robot. LOVE IT !!

  • @ThePaddingtonsChannel
    @ThePaddingtonsChannel Рік тому +1

    That "dataset" Property seems really convenient. Learned something new 👍

  • @michaelrooze278
    @michaelrooze278 3 роки тому +15

    It would be cool to see examples of how you have used these in your own code....How often are you working with vanilla JS vs a framework?

  • @hg-yg4xh
    @hg-yg4xh 2 роки тому

    He has a gift for teaching, he answered all my unanswered questions all throughout the video that I didn't know how to articulate.

  • @cybersamurai99
    @cybersamurai99 Рік тому

    I am from the future and have checked out the course, and can let everyone know at the present moment that is worth it.

  • @jaylayoung2576
    @jaylayoung2576 9 місяців тому

    Man, you're a lifesaver. I appreciate the work you put in on making these videos so straightforward, yet thorough.

  • @sanjitselvan5348
    @sanjitselvan5348 Рік тому

    Here's someone who's teaching people stuff that REALLY matters in the frontend world. Thanks a ton Kyle!

  •  3 роки тому +1

    Hi, Kyle! I really owe you big because I really like to know what I am doing and you surely explain not only how to do things but also why you do whatever you do; but I need to tell you that I hate when you, sometimes, get too rethorical in trying obsesively to make things clear.
    I give you and hipothetical example:
    We do this but you can see it because this has no content. Now we write this' content and you can see it because now this has a content that is why you couldn't see it before because it had no content but now you see it because now it has a content.
    I make this observation not to make you change your ways but hoping it might help as any feedback does.

  • @SorakaOTP462
    @SorakaOTP462 2 роки тому

    Thankss to your javascript tutorials I learned how to access all of your video files from your website, so now I can watch them for free and I also uploaded them on torrent so everyone is happy ^^

  • @mohamedyashar9940
    @mohamedyashar9940 3 роки тому

    As a beginner I found it very crystal clear to build my foundation in DOM MANIPULATION. I'm glad that I found this video @ryt time. You have did a fantastic job!! Thank you.

  • @SchnippSchnappShnappi
    @SchnippSchnappShnappi Рік тому +1

    What an unbelievable treasure was I lucky to find today)

  • @chikkiidehalvi5561
    @chikkiidehalvi5561 3 роки тому +2

    your videos are very to-the-point and worth the time, exactly what a programmer needs.

  • @FunnyInternetTrends
    @FunnyInternetTrends Рік тому +1

    Wow amazing tutorial. Thank you.
    Last part i get goosebumps.
    CSS in JS is CSS in CamelCase. Wow this changed my life

  • @maenam4520
    @maenam4520 Рік тому

    After 2 years anyone could build his dream project ?
    Great content and very helpful channel.

  • @TheStoriesKnight
    @TheStoriesKnight 2 роки тому

    I chose the right decision by subscribing you that night... Thank for all the help...Love from INDIA😍🙏🙏

    • @priyankaroberts1093
      @priyankaroberts1093 2 роки тому

      Hey Amit
      Have you created any projects in JavaScript frameworks? Are you open to opportunities in web development currently?

  • @cineverseproductions
    @cineverseproductions 3 роки тому +1

    Bro.. you have a very strong and deep understanding of these basic web development things. Everything is counted and thank you so much for helping us with such things through your videos. One of the best UA-camrs. 👍

  • @umazajacker8182
    @umazajacker8182 3 роки тому +11

    I genuinely thought this was going to be “DOM Manipulation” in a different context. Damnit.

    • @juvvalan1654
      @juvvalan1654 3 роки тому

      Good basics to start

    • @ka8205
      @ka8205 3 роки тому

      Learning how to manipulate your 'dom' amirite 😏

  • @mayankarote4750
    @mayankarote4750 3 роки тому +2

    Thank you for teaching this tough thing in a very simple way

  • @Odidi_Bee6ix
    @Odidi_Bee6ix Рік тому

    One of the Best js.DOM tutorials on UA-cam

  • @madinaabbasi3837
    @madinaabbasi3837 2 роки тому +3

    This was the best explanation thank you a lot. Also the Wow part for me was in 17:54 when it goes to style css elements by JavaScript 😻🍬👋🏻

  • @gasycube4075
    @gasycube4075 3 роки тому +3

    Yeah, I just started learning JS recently! This kind of video just make want to learn mooore! Thanks mate!

    • @TheCodingOdyssey
      @TheCodingOdyssey 3 роки тому

      Good luck with your journey. Its a rewarding one.

  • @johny962
    @johny962 Рік тому

    The toggle method is so cool!

  • @joeleone6276
    @joeleone6276 3 роки тому +1

    This material is presented very easily and understandable for many different skill levels.

  • @DigitallyAlex
    @DigitallyAlex 9 місяців тому

    You are a literal life saver Kyle, managed to help me understand how this works in such little time. Thank you!

  • @yasirtahirkheli74
    @yasirtahirkheli74 2 роки тому

    Am scratching and pulling my hair at the moment for being idiot to have been missing this truly helpful and life-saving channel. This is exactly what i have been struggling for as I plan to replace all the jquery code from my projects with plain javascript. You are a gem mate! watched and subscribed.

  • @goisborges
    @goisborges 3 роки тому

    As soon as I get some availability I'll purchase your course. Don't stop sharing content, bro. Your explanations are great.

  • @leightonbuchanan-cates3932
    @leightonbuchanan-cates3932 2 роки тому +1

    This was insanely helpful, especially your explanation about the difference between innerText and textContent. Thank you so much and keep up the amazing work!

  • @logusgraphics
    @logusgraphics 3 роки тому +1

    Your channel is amazing. The content is not only educational but very entertaining.

  • @BuzzMarketingKe
    @BuzzMarketingKe 2 роки тому

    Thanks a lot for making the world an easier place.
    much appreciation from Kenya.

  • @imbrad99
    @imbrad99 2 роки тому +1

    This video is incredibly helpful, thank you for all that you give to the community. You're brilliant and have taught me so much!

  • @flux2956
    @flux2956 2 роки тому

    Your slider carousel tutorial is much clearer now because of this video. I just had to subscribe.

  • @tiltify2393
    @tiltify2393 3 роки тому +1

    You are absolutely awesome for actually organizing your content in an actually efficient way, that's not all over the place, like every other JS tutor on the internet out there

  • @ritikyadav7238
    @ritikyadav7238 7 місяців тому +1

    Bro you are too good in explaining

  • @Peywan
    @Peywan Рік тому

    thaknks, was a good pace to follow along while you were explaining!

  • @maxlong1374
    @maxlong1374 3 роки тому

    Hello Kyle. This is the first video I watched in your channel. After watching this video, I have decided to watch ALL of your videos in your channel ASAP. I love the way you teach things. I love your mission. I'm going to like every video I've watched in your channel from now on. Thank you Amazing human.

  • @alyciariley3303
    @alyciariley3303 2 роки тому

    This is great! All of my experience has been with jQuery and I am currently refactoring my Bootcamp projects to VanillaJS for practice. You explained everything so clearly. Thank you!

  • @kevingriffin2511
    @kevingriffin2511 Рік тому

    Ever was told by your mother to clean your room but was never told how to clean your room. Well that my bootcamp in a nutshell .. thanks to you , You the father who break it down how to clean up lol

  • @Snoo29293
    @Snoo29293 3 роки тому +1

    I now got to learn about classList and dataset, I was afraid about the blog, because I had got so used to videos, but I gave a look to your article and it seemed pretty well made and short.

  • @nwokporochukwuebuka
    @nwokporochukwuebuka 2 роки тому

    Thank you sir.
    Your videos have helped me become a better developer

  • @codeAlongwith
    @codeAlongwith 2 роки тому

    I have really enjoyed this. Thanks so much.

  • @fabiomazzei9871
    @fabiomazzei9871 3 роки тому +3

    Excellent class! Thanks for sharing your knowledge. I learned a lot, sincerely.
    A thousand 'likes' for you!!!

  • @ManojSatishkumar
    @ManojSatishkumar 3 роки тому +2

    I'm in the same path as you brother. I teach web development too and have nearly a decade of professional experience

  • @AbhaySingh-dd9xc
    @AbhaySingh-dd9xc 3 роки тому +7

    Big student from india❤

  • @tasya_nabila
    @tasya_nabila 3 роки тому

    It really REALLY help meeeee. I was learning DOM at college but understand nothing at all!! Thank youuu 😢😢😢

  • @remoralite6027
    @remoralite6027 Рік тому

    Awesome content as always, Kyle! Love the Rise Against shirt :)

  • @obasaajibola3933
    @obasaajibola3933 2 роки тому

    Thank you for your teaching. It has truly helped me in solving a lot of problems I thought I could not solve.

  • @SK-vg3mw
    @SK-vg3mw Рік тому

    Thank you, your channel is a goldmine for beginners!

  • @bama2619
    @bama2619 8 місяців тому

    brief and fast, thank you.

  • @adsrinivasan
    @adsrinivasan 3 роки тому

    By far your teaching is good compared to other tutors. Thanks a ton

  • @sebastiansimon7557
    @sebastiansimon7557 3 роки тому +4

    1:31 - Another important difference: `.appendChild` returns the appended element, so you can chain methods on its return value. `.append` returns nothing. There’s also the with-scopability difference (Symbol.unscopables), which shouldn’t be too relevant in 2021…

  • @manishwalia1102
    @manishwalia1102 3 роки тому +1

    Finally I understood this concept thank u so much sir

  • @azaramirli2601
    @azaramirli2601 Рік тому

    thank you for the time you are putting in. I hope you are getting something back out of it. You are dropping golden information generously. Can you please make a video in the future about most of your favorite shortcuts you use while coding.🙏

  • @dixingxu
    @dixingxu 2 роки тому

    love the jackson in your background

  •  Рік тому

    woot Rise Against T, now I know why I like your style!

  • @davejackson88
    @davejackson88 Рік тому

    that jackson on the back is amazing

  • @phamelamhlaba4024
    @phamelamhlaba4024 4 місяці тому

    I kinda have an idea of of DOM Manipulation. Thank you🙏🏾

  • @VladdyHell
    @VladdyHell Рік тому +1

    # Methods:
    - createElement()
    - append()
    - appendChild()
    - remove()
    - removeChild()
    - getAttribute() | .
    - setAttribute() |

  • @vergilkelley2378
    @vergilkelley2378 3 роки тому

    you deserve 2 thumbs up. love your content, you make it easy to understand!

  • @101kawsar
    @101kawsar 2 роки тому

    An alternative to innerHTML is insertAdjesentHTML. Very helpful working with data coming from API.

  • @azsamsiizbrah
    @azsamsiizbrah 3 роки тому +2

    Great video, keep the good work up! About the remove() vs removeChild(), the latter could be more useful when you have already selected the parent and don't want to specifically select the child element on a separate row. Here's what I mean by that with the current example:
    div.removeChild(div.lastChild); //removes the "Bye"

    • @Victor_Marius
      @Victor_Marius 3 роки тому +3

      remove() is not supported in older browsers (I mean Internet Explorer 11) 😂
      But sometimes you need to make it work on those dinosaurs

    • @ethisfreedom
      @ethisfreedom Рік тому

      @@Victor_Marius true specially when you’re working on legacy codes

  • @techbizcanada7594
    @techbizcanada7594 3 роки тому

    Thank you. You're a good teacher. Your presentation style is clear and concise. I like that very much.

  • @jonathanmsmith
    @jonathanmsmith 3 роки тому +2

    Came for the web dev instruction, stayed for the Rise Against shirt

  • @rayankhan12
    @rayankhan12 2 роки тому

    This is by far the best video on JS DOM manipulation I've ever watched! I would've given it a million likes if I could! :p Thank you soooo much Kyle :)

  • @akarihotech
    @akarihotech 9 місяців тому

    Kyle you are a God-given

  • @thepopstudio2354
    @thepopstudio2354 3 роки тому

    You are phreaking awesome! thanks

  • @dawarlatif3832
    @dawarlatif3832 Рік тому

    your way of teaching is elite, there's a request to make a tutorial series on NesstJs framework

  • @heritiersefu4539
    @heritiersefu4539 Рік тому

    Bro this is the best DOM video. thanks

  • @Supernova12034
    @Supernova12034 Рік тому

    Great video! really helped nail down the DOM concepts for me.

  • @jlambert12013
    @jlambert12013 2 роки тому

    So many question I’ve had for months were answered in this video.

  • @petemoss3160
    @petemoss3160 Рік тому

    This really should have been the first thing i learned. Got lost for months in learning about frameworks and compilers and bundlers and ... back to basics with 'VanillaJS' and 'web components', can't go wrong! (actually, using Vite for live reload, production bundling, and TailwindCSS - all the tooling needed.)

  • @valentinleguizamon9957
    @valentinleguizamon9957 4 місяці тому

    thank you, although chatgpt-4o and later versions will take over, I'm learning all this because I was lucky enough to earn a scholarship lol. Besides learning is lovely, thanks!!

  • @514fadeaway8
    @514fadeaway8 3 роки тому

    THANK YOU KYLE {hope that's the way you spell it}
    completed my assignment with this one video but their soo much to learn

  • @kwalsh7107
    @kwalsh7107 Рік тому

    I really appreciate your videos. Explained really well. Thank you!