How to create a new element in DOM | chai aur

Поделиться
HTML-код
  • Опубликовано: 24 дек 2024

Комментарии • 814

  • @shobitkhatri9242
    @shobitkhatri9242 11 месяцев назад +13

    26:28 timestamp
    here is the code:-
    const arr1 = ['ashish','bhanu','naveen','gautam']
    const arr2 = ['blue','green','yellow','red']
    arr1.forEach( ( text,index ) => multipleButtons(text,arr2[index]))

    function multipleButtons(text,bgColor)
    {
    const button = document.createElement('button')
    console.log(button)
    button.setAttribute('className','firstbutton')
    button.setAttribute('type','submit')
    button.style.backgroundColor = `${bgColor}`
    button.style.cursor = 'pointer'
    button.style.padding = "12px"
    button.style.borderRadius = "10px"
    const textnode = document.createTextNode(`${text}`)
    button.appendChild(textnode)
    document.body.appendChild(button)
    }

  • @shreshthagupta7771
    @shreshthagupta7771 Год назад +155

    16:00 Important discussion about NodeList. A nodelist is a collection of document nodes which includes text nodes , attribute nodes and element nodes. A line break is also counted in nodelist but only first one. All subsequent line breaks are ignored by browser

    • @adideveloper
      @adideveloper Год назад +4

      op

    • @talhakhan4684
      @talhakhan4684 Год назад +7

      Comment nodes as well by the way. And I have a question, you said line break is also counted in nodelist but only the first one but I think all the lines breaks are counted and they are represented as textNode in nodelist. Correct me if i am wrong.

    • @Asadullahabbasi-mi6cq
      @Asadullahabbasi-mi6cq Год назад +10

      @@talhakhan4684 you are right not first one but every line break is counted but if there are multiple ine breakes simultaneously or right after same node than they are ignored

    • @hemantprasad5972
      @hemantprasad5972 5 месяцев назад

      comment is also counted

  • @ruchikarawani
    @ruchikarawani 3 месяца назад +7

    I SWEAR THAT I HAVE WATCHED A LOT PEOPLE'S JS COURSE , PAID AND FREE BOTH BUT KABHI KISI NE HITESH SIR JAISA EXPLAIN NHI KIYA HAI, EXCELLENT JAVASCRIPT COURSE MAN, THE BEST JAVASCRIPT COURSE I HAVE EVER WATCHED , RESPECT💯

  • @Emporer_7
    @Emporer_7 5 месяцев назад +6

    I'm from Andhra Pradesh and my language Telugu and I'm just average at Hindi and still I can able to understand your classes very clearly becoz of your Slow and Clear explanation and pronounciation Thank you so much Hitesh Sir

  • @shwetanshu13
    @shwetanshu13 10 месяцев назад +7

    This is undoubtedly the best structured JavaScript course. Not unnecessarily long and very informative.

  • @nusratlines4947
    @nusratlines4947 Год назад +201

    Jab jab mushkil Lagta..Bhai kehta Hy..ye to basic tha.....

    • @Bharat_Rider
      @Bharat_Rider 10 месяцев назад +6

      😂😂🤣🤣🤣

    • @Thezaintaseer
      @Thezaintaseer 10 месяцев назад +1

      Bhai khta hai basic hai .. agly bndy ki bund path k hath ma ajati hai😮

    • @LearnWithManan.110
      @LearnWithManan.110 9 месяцев назад +1

      Right Bro😅😅

    • @aadilyt1573
      @aadilyt1573 8 месяцев назад +3

      Us bro us 😢😂

    • @codingvampire1
      @codingvampire1 8 месяцев назад

      Bc har cheez pe basic hahahhah hum toh chutye ha

  • @oqant0424
    @oqant0424 10 месяцев назад +4

    27:20 wakai me ab confidence aa raha hai JavaScript me
    Thanks a ton Sir ❤❤

  • @mahmudulhasan1210
    @mahmudulhasan1210 8 месяцев назад

    This is undoubtedly the best structured JavaScript course. Not unnecessarily long and very informative.

  • @divyanshsharma673
    @divyanshsharma673 10 месяцев назад +2

    You're an amazing teacher, I was used to learn JavaScript by myself but I wasn't ever confident. One of my friend suggest your playlist to me, and now I'm looking for the react series as well. I like the friendly way of your teaching.

  • @Fusion-Flow
    @Fusion-Flow 4 месяца назад +4

    Best JavaScript series I’ve ever watched.
    Thank you Hitesh Sirr❤

  • @AhmedRehan01
    @AhmedRehan01 8 месяцев назад +5

    I have done js from various courses and yt Channel but no have explained in such depth really thankful to you

  • @hassanghani8039
    @hassanghani8039 Год назад +4

    never ever thought that i will ever learn javascript with this much depth Hats off boss love from pakistan
    really excited for next videos and react series

  • @arghyadeepkundu5664
    @arghyadeepkundu5664 9 месяцев назад +1

    this lecture teaches us easily about DOM.. You have an incredible teaching skill.

  • @parmjeetmishra2
    @parmjeetmishra2 Год назад +1

    Now I have a superb confidence in me about javascript and even I can read documentations easily.
    Please start React after finishing this.

  • @abhihirwani4403
    @abhihirwani4403 Год назад +5

    finally I have get the very good and very deep knowledge of the DOM your videos are just like a series, love to watch and learn new concepts of JavaScript please make more videos on that and please also create video on the behind the seen of react github

  • @AishaAkram-jt7fy
    @AishaAkram-jt7fy Месяц назад

    This is undoubtedly the best structured JavaScript course. Not unnecessarily .Thanks a ton Sir ❤❤

  • @sonaliparihar3382
    @sonaliparihar3382 2 дня назад

    you are best teacher sir ,there is no competition of yours in the entire youtubers who make coding series ,you are bestest in all among...thankyou sir for making javascript concept so easy for us.

  • @MayankChoubey-j8m
    @MayankChoubey-j8m 11 месяцев назад

    good very good excellent hitesh sir, maine kafi teachers se DOM or javascript padhne ka koshish kiya magar pata nhi kyun har baar DOM ki baari aane per kuch samjh nhi aapata tha, maine koshish ki per mujhe nhi hua, aur fir maine aapki chai aur javascript course ko pichle 26 dino se padh rha hun aur ab mujhe wakai lag rha ki "Haan,maine kuch sikhaa hai sir". Aapne kya jordaar tareeke se javascript padhaya hai, padh ke maza hin aagya aur khaskar DOM ko itne behtareen aur indepth explain kiya ,i loved that.thankou aisehin aap achhe achhe contents daalte rahen

  • @Bug_Debug
    @Bug_Debug 10 месяцев назад

    Addicted to CHAI (earlier) , aur CODE(Now)...
    Thanks Sir for making this series, have been searching for such DOM Videos from so long...

  • @KrishJaiswal-fr6gn
    @KrishJaiswal-fr6gn 4 месяца назад +2

    Kafi acche se DOM samjhaya aapne sir thnks.

  • @rameshwarmangal3971
    @rameshwarmangal3971 Месяц назад

    Really best javaScript playlist,even better than some paid cources

  • @adarshpatel5791
    @adarshpatel5791 4 месяца назад +3

    Good teaching skill, sir.
    Even though bigener can easily understand.

  • @JeetuKumar-wd1uw
    @JeetuKumar-wd1uw Год назад +12

    After watching this lecture i fell i should learn again javascript❤❤❤😢 never see such a awesome content on free course😊😊😊

    • @ankursinger102
      @ankursinger102 Год назад +3

      Bhai Same feeling...

    • @manishasaini307
      @manishasaini307 11 месяцев назад +1

      @@ankursinger102 same to same bro

    • @rajendrakumarsharma674
      @rajendrakumarsharma674 2 месяца назад

      I have been 1 year in web development and I am feeling like I am learning JavaScript for the very first time, he teaches on the basis of practical approach

  • @freek937
    @freek937 8 месяцев назад

    Completed the Whole Lecture in One Sitting while writing code and practicing different examples.

  • @devendra_Selokar04
    @devendra_Selokar04 Месяц назад

    Thankyou Hitesh Sir for the wonderful Detailed Series iF Javascript

  • @aryanbhatt5934
    @aryanbhatt5934 5 месяцев назад

    beginners like us are very struggling with learning js.. You are making the best efforts to vanish that struggle.. Thank You sir

  • @Jamshaid.Developer
    @Jamshaid.Developer 2 месяца назад +1

    really you are great sir that is course helpfull for every beginner student before it seems i cannot learned javascript but now it seems i can javascript and now i do javascript thanks you very much sir ❤❤❤❤and you are hero for me and every beginner student

  • @Instrumentation010
    @Instrumentation010 Год назад +8

    I had learnt javascript from paid course on Udemy but could not built a single project or even could not understand what was going on, but I knew basic javascript so I started to watch your react videos after saw your teaching style I decided to learn javascript from your videos and now i am quite confident to build a project, thank you sir for such amazing move to provide practical knowldege.

  • @RahulKumar-ng8rs
    @RahulKumar-ng8rs 10 месяцев назад

    (1) VIDEOMARK 16:00 Important discussion about NodeList.
    (2) At 23:38 Why we should use document.createTextNode('Text to be inserted') instead of element.innerText = 'Text to be inserted' ,
    Reason is: innerText first fetches the default value and then update it with our value, while createTextNode() directly updates the value, so it saves us from the round trip, hence more optimised code.

  • @theartistbhavik
    @theartistbhavik Год назад +4

    Thank you for this entire series ! 🙌

  • @haariskhan961
    @haariskhan961 9 месяцев назад +3

    00:06 Understanding the Document Object Model (DOM) is crucial for cracking interviews and React development
    01:51 Learn how to create new elements in the DOM using JavaScript
    05:32 Select the parent element and find out what values are inside it
    07:29 Accessing and manipulating elements in the DOM using inner HTML
    11:17 You can select the parent element using querySelector method in JavaScript
    13:06 The DOM represents the HTML document as a tree structure
    17:22 How to programmatically create a new element in DOM
    19:24 Creating a new element inside the dev variable
    22:51 To attach a child element to the DOM, use the document to specify the parent element.
    24:34 Creating a text node with a value in DOM
    27:45 The video ends and invites viewers to watch the next one.
    Crafted by Merlin AI.

  • @KushareHarshal
    @KushareHarshal 10 месяцев назад +1

    Sir I am from Your "PW Web Development Batch".... 😊
    Aapke bina padai nahi ho rahi thi to Search Karate huye...Aap mil hi gaye Ab to sirf build karana hai...
    Thanks lot
    Respected❤

  • @AnimationVO
    @AnimationVO 2 месяца назад

    "Yeh toh basic tha, yeh toh aapko aata hoga" 😭😭😭 this line got me. Mjhey yeh smj nhi aata key mein hi akela wo bnda hun jis ko basic hi nhi smjh aata

  • @suyashpampatwar9321
    @suyashpampatwar9321 Год назад

    16:00 Important discussion about NodeList. A nodelist is a collection of document nodes which includes text nodes , attribute nodes and element nodes. A line break is also counted in nodelist but only first one. All subsequent line breaks are ignored by browser

  • @usmaanahmed9450
    @usmaanahmed9450 10 месяцев назад

    Created function as hinted at the end, works perfectly 🤌
    function addDiv(text,color) {
    let div = document.createElement('div')
    let addText = document.createTextNode(text)
    div.style.padding = "12px"
    div.appendChild(addText)
    div.style.backgroundColor = color
    document.body.appendChild(div)
    }
    addDiv("usman","red")

  • @aasifalinoonari9709
    @aasifalinoonari9709 6 месяцев назад

    16:44 | A Line break or space is taken as a text node. If we put two divs together without any space or line-break (enter) in one line in HTML there will be no text node between those two divs.

  • @shreyakolekar4059
    @shreyakolekar4059 Год назад +1

    Thank you for this entire series! Hindi mai JavaScript sikhnese ye saare concepts lifelong yaad rahenge.

  • @tarunkatre9809
    @tarunkatre9809 11 месяцев назад +7

    21:39 for learners id in an element can not be started by a number
    Btw I don't regret starting this playlist 😄 amazing content by hritesh sir

  • @dalone2626
    @dalone2626 Год назад +3

    i wish i founded this corse 3 months ago, i was searching youTube and founding corse and cores but cound't learned JS, now i have found amazing course, with amazing mentor, thank you form bottom of my heart❣❣

  • @iqbal0725
    @iqbal0725 Год назад

    I’m from Pakistan but your Urdu is so perfect. Your videos are excellent resource to learn DOM manipulation in JavaScript

  • @rakshitchauhan3266
    @rakshitchauhan3266 2 месяца назад +1

    Aree Sir ek baat bolu , aap kuch bhi padhte ho mst padhte ho mn kerta hai sab kuch padh lu 😅 but majboor hu course se related hi padhna hota hai , literally Sir aapke bolne ka style uff dil or dimaag dono per raaj kerta hai mn khush ho jata hai aapse padhke 😊

  • @Dev-Phantom
    @Dev-Phantom 11 месяцев назад

    Best Dom Lecture Ever, on youtube.

  • @tarunsikarwar
    @tarunsikarwar Год назад +2

    perfect series of javascript and perfect teaching style?

  • @Knwld
    @Knwld 4 месяца назад

    Greatest explanation sir!! ...... Really thankful from my bottom of the heart to this greatest personality @chai and code

  • @subratkumarnayak2560
    @subratkumarnayak2560 5 месяцев назад

    SIr I'm currently doing your 30-days Javascript Challenge, and these videos helped me to learn the concept and the challenge helped me to apply those learning....

  • @virajagarwal1714
    @virajagarwal1714 6 месяцев назад

    sach bolu toh I never thought ki mere ye topics itne ache se clear he=onge. Thanks you sir for such a lovely topic discussions.

  • @VishalSharma-rn7mt
    @VishalSharma-rn7mt Год назад +1

    Awesome Sir, learned the very important concept
    Aap hamare liye legend Guru hai ♥

  • @Dynamite_77_5
    @Dynamite_77_5 Месяц назад

    Thank you so much for excellent explanation hitesh !!❤❤❤

  • @AmanKumar-dm8mn
    @AmanKumar-dm8mn 8 месяцев назад

    Sir I have done js from various courses and yt Channel but no have explained in such depth really thankful to you ❤❤

  • @adarshdwivedi5395
    @adarshdwivedi5395 Год назад +3

    Great series .. i learn a lot.we wanna more in dept concept .
    Carry on sir..🎉

  • @BitFire007
    @BitFire007 9 месяцев назад

    "Chai aur Code, you've cracked the code to teaching JavaScript effectively. I'm hooked!"

  • @singhamita
    @singhamita 8 месяцев назад

    16:00 Child nodes very nice and important discussion !!

  • @singhamita
    @singhamita 8 месяцев назад

    Thank you for rolling out such a quality content . Your contents are dopamine booster for soul lost in modern world of tutorial hell !!

  • @AshwaniPatel-b5z
    @AshwaniPatel-b5z 4 месяца назад

    Maine bahut se vidseos dekhe hai youtubers k but unme se sabse behatareen aapke hai

  • @rohitsingh04141
    @rohitsingh04141 9 месяцев назад

    Sir Your Teaching Method Put the beginners in Love with JS. A lots of Love for Chai and Code.

  • @ro0t115
    @ro0t115 10 месяцев назад

    On 5th day of learning JavaScript __, I did not comment on previous videos because I was sprinting fast through this video series but now ek appreciation comment toh banta hai Hithes ji ke liye ... well done Hitesh ji and then 16:00 .childNodes --> gives nodeList

  • @akshayjain2777
    @akshayjain2777 Год назад +3

    thankyou so much sir sir please do continue this series sir . your videos have made javascript so easy to learn
    😍

  • @DeveloperArhamAli
    @DeveloperArhamAli 6 месяцев назад +1

    this course has no price because this masterpiece is priceless

  • @phoolkumari1563
    @phoolkumari1563 Год назад +13

    रोज इसी का इंतजार करते हैं आज पुनः मिल गया

    • @chaiaurcode
      @chaiaurcode  Год назад +25

      1 aur video editing me gya hua h, kl vo b aa jayega

    • @manendersingh6514
      @manendersingh6514 Год назад

      Sir itna wait mt kraya kro 2 din m video upload kr diya kro❤❤❤

    • @ashishjat7413
      @ashishjat7413 Год назад

      ​@@chaiaurcodeplz sir video dalo

    • @Arnav404
      @Arnav404 Год назад +1

      @@chaiaurcode waiting for the next video

    • @samiransari-fg6kx
      @samiransari-fg6kx Год назад +2

      ​@@manendersingh6514Bhai unke office works v h family v h Thora unke bare me v socho.

  • @learnforsurvival1208
    @learnforsurvival1208 Год назад +2

    This tutorial I felt is really helpful....theories and practical balance is of top notch

  • @anupammishra2891
    @anupammishra2891 8 месяцев назад

    sir you absolutely right that.......i have confidence about java script because of you ......thanks a lots

  • @supriyaghanekar3904
    @supriyaghanekar3904 4 месяца назад

    just awesome series!! thank u so much

  • @Waleedkhan-zh8hm
    @Waleedkhan-zh8hm Год назад +7

    Sir Your Teaching Method Put the beginners in Love with JS. A lots of Love for Chai and Code.

  • @SuryaKarigar
    @SuryaKarigar Год назад +6

    15:00 Important NodeList discussion. Very different from previous video in which we learnt to make basic DOM structure 🌲.

  • @ajaysinghrathour8622
    @ajaysinghrathour8622 Год назад +1

    I am learning a lot of thing from this series. Thanks a lot sir for this series. - Ajay Singh

  • @janankhan6017
    @janankhan6017 Год назад

    You Are a Great Teacher Sir G... Your Teaching Style or Method is so Good. Salute to You

  • @Memelustreels
    @Memelustreels 2 месяца назад

    One of the most satisfied Playlist sir ❤ Mahadev bless you

  • @RahulGupta-ki6mf
    @RahulGupta-ki6mf 10 месяцев назад

    Its always great to have you sir for javascript learning path as I have tried to learn from many others but failed to know the deep concept of javascript and also felt low. But now I am confident in it and trying to stick with you for learning javascript backend as well.

  • @Prabhat_Sharma5
    @Prabhat_Sharma5 4 месяца назад

    best javasript course on youtube

  • @muhammadnoumanumer4282
    @muhammadnoumanumer4282 10 месяцев назад

    Amazing Person. Your speaking style is so good and polite & you exactly know how to deliver.

  • @funkyboy4882
    @funkyboy4882 Год назад

    16:00 Yaha se childNodes explain kiya hai, bhaidya concept laga , deep understanding milli ki kaise jo code hamare liye 5 lines ka hota hai browser usse kitne hisso mai todta hai and kis data structure ka use karta hai and kaise render karta h, awesome 🔥🔥🔥🔥

  • @somajana6638
    @somajana6638 11 месяцев назад

    Your tutorials are addictive. The learning becomes fun with in depth understanding.Thanks so much.

  • @kalibsamsongill3389
    @kalibsamsongill3389 7 месяцев назад +1

    nhi sir ap bht mehnat kar rahy hein khuda apko or bhi zda barkat de

  • @heyMonikaa
    @heyMonikaa 9 месяцев назад

    The humbleness is just another level

  • @vaibhavilohani3421
    @vaibhavilohani3421 11 месяцев назад +1

    Thank you so much sir!!Excellent explanation!

  • @Poojapaul-i5y
    @Poojapaul-i5y 3 месяца назад

    still sir this series now help alot because i am learning javascript thankyou sir

  • @technologiesmotivationd7754
    @technologiesmotivationd7754 Месяц назад

    Your Teaching style such a amazing and unique

  • @CineCrave_Sriese-t6e
    @CineCrave_Sriese-t6e 2 месяца назад

    lecture complete 👍👍 thank you sir

  • @harshvardhanjha473
    @harshvardhanjha473 3 месяца назад

    sir this course really help me to understand Basics of JavaScript

  • @anirudhr4710
    @anirudhr4710 8 месяцев назад +1

    Such an amazing lecture man salute

  • @rohitranjan6085
    @rohitranjan6085 Год назад +1

    Great Series Sir . DOM concepts is 'lit' 💥

  • @iamkmsyed
    @iamkmsyed 10 месяцев назад +1

    16:34: Node List Discussion

  • @Shravankumar_888
    @Shravankumar_888 Год назад

    cant thank you enough sir this cannel has very very bright future keep on doing , everyone love you sirji

  • @RahulSharma-wz6yv
    @RahulSharma-wz6yv 10 месяцев назад

    16:00 Important discussion about NodeList.
    26:00 for better approach of inner.HTML

  • @thecalgarians4597
    @thecalgarians4597 9 месяцев назад

    This video was the MOST MIND BLOWING of all 33 vids till now.
    The way you explained a not-so-easy workflow in such an easy manner... Kudos, HItesh ji
    ♥🧡🧡

  • @ankita1122-n8
    @ankita1122-n8 Месяц назад

    Seriously this is osm.Thank you sir😊

  • @amit16_01
    @amit16_01 8 месяцев назад

    Respected Sir, Your teaching style is very unique. like💯💯💯💯💯💯💯💯💯💯💯💯💯

  • @Bigaimstars
    @Bigaimstars 5 дней назад

    grateful to have this kind of video

  • @mbgreat03
    @mbgreat03 2 месяца назад

    Thank you for this entire series ! 100

  • @Vedicaa
    @Vedicaa 11 месяцев назад

    this is the best series on RUclips for javascript fr

  • @tarunsharma4402
    @tarunsharma4402 3 месяца назад

    really a amazing javascript playlist 🔥

  • @Abhinav-ep7vb
    @Abhinav-ep7vb 6 месяцев назад +1

    Best Js Series on Yt

  • @abdulmatania8155
    @abdulmatania8155 Год назад +1

    18:48 -> create new nodes

  • @haariskhan961
    @haariskhan961 9 месяцев назад

    bhai ur teaching level is unmatched

  • @atharvadeshmukh6328
    @atharvadeshmukh6328 Год назад

    BEST JAVASCRIPT PLAYLIST EVER !!
    Thank you so much Hitesh sir!!😀😀

  • @bhartiom560
    @bhartiom560 Год назад +1

    Thank you so much sir for this series..Please do continue.

  • @akankshabholane9354
    @akankshabholane9354 3 месяца назад

    I have watched many videos on youtube related to javascript to clear my concepts but after watching this series i dont feel the need to look for another videos

  • @pannerbiryani3002
    @pannerbiryani3002 3 месяца назад

    Amazing video! Your helping us alot in web dev!

  • @krunalpatel7437
    @krunalpatel7437 7 месяцев назад

    Excellent Content which I have Watched on RUclips.
    Satisfied Content.😍

  • @NattyTrader
    @NattyTrader 9 месяцев назад

    This series was very helpful..............Thank you!!