JavaScript ES6 Modules

Поділитися
Вставка
  • Опубліковано 25 січ 2019
  • With ES6 JavaScript changed from a programming language that many people dreaded using to one of the most popular and loved languages. Of the new changes in ES6 the addition of modules was one of, if not, the biggest change that pushed JavaScript to where it is now. Modules make it so much easier to write clean and reusable code. In this video we will discuss how to use ES6 modules and why they are so important to JavaScript.
    ES6 Modules Article:
    blog.webdevsimplified.com/202...
    Async vs Defer Video:
    • What Is The Fastest Wa...
    Twitter:
    / devsimplified
    GitHub:
    github.com/WebDevSimplified
    CodePen:
    codepen.io/WebDevSimplified
    #JavaScript #ES6 #Modules

КОМЕНТАРІ • 397

  • @johnniestang
    @johnniestang 5 років тому +180

    Dude ... I've watched a lot of videos recently trying to understand ES6 modules and why they weren't working for me. You nailed my issue and cleared up a lot of confusion.

    • @WebDevSimplified
      @WebDevSimplified  5 років тому +19

      I'm really glad my video was able to help!

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

      Kyle is a very gifted presenter. Very. You are right.

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

      true, I haven't seen in any other tutorial that I have to type in script type="module" , I was wondering why my function calls are not working in other .js file

  • @shiytp
    @shiytp 4 роки тому +141

    you really live up to your channel name. i've been through countless channels to get a better grasp on ES6 and yours are by far the best. other channels tend to speedrun their tutorials without explaining everything while you do it nice and simple. wish i found you sooner.

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

      I've come to the conclusion that this guy is the worst teacher ever seen. He explains like a monkey with brain damage. I don't know what you're talking about but this is terrible on so many levels.

  • @thomasm1964
    @thomasm1964 2 роки тому +6

    What a beautifully clear, succinct, calm and focussed video! I learned more in five minutes of watching you than I have in hours of reading elsewhere. Brilliant!

  • @noah.2628
    @noah.2628 3 роки тому +3

    Dude, thank you soo much. Before I was so confused/stuck on "require" topic but now since you've explained it to us in such a way I can understand it now. Once again, thank you!

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

    Still the best learning channel for me, simple, straight, and sharp information. Keep up the good work bro. Thanks.

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

    OMG what an awesome way to explain it. I literally spend 3 days without understanding how export and import worked and you made it seem so easy through coding and examples!! I definitely susbscribed!! Keep it up!! Thanks so much!

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

    You are a Godsend! No amount of time spent on 100s of tutorials and documentation made me understand JavaScript as much as your videos did. Kudos!

  • @Huy-ed2re
    @Huy-ed2re 4 роки тому +40

    Literally the best ES6 tutorials on the internet. So simple yet so powerful :)

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

      I've come to the conclusion that this guy is the worst teacher ever seen. He explains like a monkey with brain damage. I don't know what you're talking about but this is terrible on so many levels.

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

      I'm Chinese, love this, he help me past me master classes.

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

    Thank you so much,
    I learned export and import in js very easily for the first time.
    I loved the way you only used export keyword before functions and that you explained default export very well.
    Best wishes

  • @samdavepollard
    @samdavepollard 9 місяців тому +2

    that rare thing - a tutorial about modules which doesn't assume I already know how to use modules
    many thanks for sharing your knowledge; totally got me up and running
    subbed

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

    Your videos are always the first I watch when I'm learning new things.
    Another great video!
    I have a question... Where does the exported data live? Is it loaded in client's memory?

  • @kenkioqqo
    @kenkioqqo 2 роки тому +14

    Your explanations are top-notch. Your choice of what to teach is very relevant, especially to beginners, like me. I have been following your videos for the last few months, and they are really helping me understand JavaScript. It's very hard to quit when there are content creators like you to help. Keep up the great work bro.

  • @PapaBear_Gaming
    @PapaBear_Gaming 4 роки тому +1

    Thank you so much for this. Just going over this topic and it looked rather confusing until you went over it :)

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

    I have a CodeCademy account, and the funny thing is: after doing the exercises there or if I'm stuck, I come here and get the better understanding of the subject. Please keep these videos up! xD

  • @getrekt1386
    @getrekt1386 5 років тому +4

    came across this channel for some revision, amazing content

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

    Such a clear explanation of a subject that so many Devs struggle with explaining to beginners

  • @ayahatheel2744
    @ayahatheel2744 3 місяці тому

    Thank you, I'm actually going through a coarse over coursera and you just made it way easier. Appreciate it

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

    Thought it was about time for me to learn how to use ES6 modules. I thought this video was practical and to the point. I can put to use what I learned from it right away. Thanks!

  • @lovewords72
    @lovewords72 Місяць тому

    Thank you very much for this video. I was stuck as I was getting errors then after adding - type='module' in script tag in HTML everything resolved. I am grateful for this video.
    Thanks for the help!

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

    Thanks for your work! I have to say, I think you are the best youtube about javascript/web that I have seen. Thank you so much :)

  • @eddyqiu5161
    @eddyqiu5161 5 років тому +36

    Looks like I need to run that code with Live Server in order to avoid getting errors related to CORS Policy. Great tutorial! Subbed.

    • @royalenfieldmeteorrider7873
      @royalenfieldmeteorrider7873 4 роки тому +5

      thanks to Ritwick Dey for gifting us Live Server

    • @333jjjjjj
      @333jjjjjj 2 роки тому +2

      This is important and should have been mentioned in the video.
      - a guy who learned this the hard way 30 minutes into a timed interview assessment, no servers allowed. Now, i still passed since i have chops. Close call though

  • @rodneytapit5636
    @rodneytapit5636 10 місяців тому

    These are the best tutorials on the internet, you are a talented natural teacher.

  • @thien837
    @thien837 2 місяці тому

    great video! I was reading the doc and it toasted my brain. i didnt understand anything but i got it instantly after wathcing this. you explained the concepts very well 👍

  • @javascriptmastery
    @javascriptmastery 5 років тому +4

    Continuing to provide awesome content, as always! 🔥

  • @SlingShotKid007
    @SlingShotKid007 5 років тому

    This was right to the point with a lot of great info in a short video. Thanks, subbed

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

    Really nice videos, finally I kind of understand modules, i´ve been fighting them in the new versions of three.js and its driving crazy,.

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

    Very clear, well-explained, step-by-step js juice here. Thanks!

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

    You are always king 👑. Your teaching style is very organized!

  • @TrouvatkiDePercusion
    @TrouvatkiDePercusion 4 роки тому +1

    Holy fucking shit... I finally understand what modules are, and not only that, now I finally understand when you're supposed to use braces in import statements and when not to... Bro, you deserve to be world-famous, seriously. This is amazing.

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

    Keep it up, mate, you are doing a fantastic job here. Thanks for that! ;)

  • @Bayo106
    @Bayo106 4 роки тому +65

    damn, imagine knowing this before learning React. Here I am thinking this looks just like React but obviously it's just JS syntax that I was un familiar with before starting with React

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

      Bayo106 It is always suggested one learn the underlying language basics before working with or learning a framework. It can make it very difficult to see the difference between JS and the framework.

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

      I also thought the same thing. I had a hard time trying to learn React, but now I know that JS was what I didn't know back then.

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

      i came here to learn modules bec they say that it's a pre-requisite in learning react. haven't started react tho

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

      You can actually use React with ES6 modules because React is a library and not a Node.js framework. See i5ar/create-react-without-jsx-app on GitHub.

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

      @@RyanValizan obviously but I didn't know es6 to this extent

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

    Besides traversy ,dev ed and 2 more good guys I subscribed to your channel too. U are great dude.

  • @Datdus92
    @Datdus92 5 років тому +21

    This channel is a goldmine! :D

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

    Thank you. Kyle. You teach so well that I can follow you and understand..

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

    Explained in a very simple way and just in minutes.

  • @sib3709
    @sib3709 5 років тому +2

    Super clear beginner friendly explanation! Thx!

  • @zm690
    @zm690 4 роки тому

    Your explanation is so clear, every time..

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

    Thank you for this crystal clear video!
    Boom, you got a new subscriber 😁

  • @anticsBack
    @anticsBack 4 роки тому +5

    Very good and simple explanation, both for beginners and people who want to revise. Like + subscribed.

  • @sandesh.sukubhattu
    @sandesh.sukubhattu 2 роки тому

    Thanks.
    Really awesome short and depth video. Cheers

  • @Capicuaman
    @Capicuaman 5 років тому +4

    I actually did enjoy the video, very much. Thanks

  • @ecarbajal1982
    @ecarbajal1982 4 роки тому

    My man great VIDEO! Totes helping me out with my development. Keep up the awesome work and I hope you getting paid!

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

    What to say! Man your a genius, a champ. You make things so simple to understand..

  • @kavehramzanzad
    @kavehramzanzad 4 роки тому

    Hey Man You are awesome, thank you for this amazing work! well done!

  • @pixzelplethora9815
    @pixzelplethora9815 4 роки тому +1

    This really helped. Nice simple lesson to drive home fundamentals. Thanks!

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

    This guy explain everything in a very good way, like it!

  • @sagarkhasnis5991
    @sagarkhasnis5991 4 роки тому

    This cracked open modules for me finally, thanks!

  • @basiccodingwithadam8125
    @basiccodingwithadam8125 5 років тому +2

    Great explanation! First time viewer +1 subscriber

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

    You made me feel like this was easy enough and i should have known this a long time ago, but not in a bad way.

  • @zxenon_
    @zxenon_ 4 роки тому

    Very clear and straightforward explanation...
    One thing I want to point out... for God's sake, master the language not the framework.
    When one masters new Js capabilities, it is easier to understand tools like VueJs and React and not see them as a magic blackbox.

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

    can't be any clear than this explanation. bravo to you. you the best

  • @imajt5
    @imajt5 4 роки тому

    really like the way you explain the thing. Just to the point. Thanks.

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

    Nice video... You should use the `.mjs` extension for modules so you know the file is a module without even open it.

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

    Neat and simplified Explanation :). Thanks.

  • @kostiantynkarzhanov9216
    @kostiantynkarzhanov9216 11 місяців тому

    Thank you! Very well explained! 💛

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

    Crystal clear explanations, as usual. I have a question, though: What does Babel do? Does it turn our modules into IIFEs?

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

      A year later i will answer this. It converts es6 and up to older version of js for browsers that dont support somwthing is es6 or up

  • @ZoroastrianCowboy
    @ZoroastrianCowboy 4 роки тому

    Great channel man, thanks for the great videos

  • @blonduose
    @blonduose 5 років тому +2

    thanks! will probably watch more of your videos as I embark on my JS journey!

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

    Best explanation I've heard so far So exports is kind of like public in c sharp

  • @abhiii3068
    @abhiii3068 19 днів тому

    Clear and to the point. Thanks!

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

    Very helpful, thank you Kyle 🙏🏻

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

    Thank you very much for this :) It was very informative :)

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

    you really simplified it!!! Thank you!

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

    Good Tutorial. Thanks. Btw, Are you deliberately avoiding Semicolons ( ; ) in each lines??

  • @Spades340
    @Spades340 5 років тому +9

    Well done. I feel like I learned a lot in a short amount of time. Subbed.

    • @WebDevSimplified
      @WebDevSimplified  5 років тому +3

      That is great! That is my goal with these videos.

    • @NeilTruick
      @NeilTruick 5 років тому

      Same here. Came for a snack...got a meal. 👍

    • @WebDevSimplified
      @WebDevSimplified  5 років тому +1

      @@NeilTruick I like that analogy.

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

    Thank you so much!
    You just made my day.

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

    really well explained! Thank you:)

  • @curtis6604
    @curtis6604 4 роки тому

    YOU DESERVE WAYYYY MORE VIEWS MY MAN

  • @himbary
    @himbary 5 років тому

    Great, thanks! Short and on the point

  • @briandacallos4234
    @briandacallos4234 3 роки тому +6

    He is the new Bucky Roberts

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

      Bucky Robert is the first greatest free GOOD tutorial that happened to us on UA-cam... with detailed free lectures. then traversy media, fireship, webdev SIMPLIFIED... GREAT GUYS

  • @loverphp5605
    @loverphp5605 4 роки тому

    perfect video and very high significant information thanks for you and keep going

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

    As always, thank you so much.

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

    thanks bro, you save me a lot in the deadline..

  • @sonysantos
    @sonysantos Рік тому +3

    +1 because you are so spontaneous that you include your own faults and recognize them. That places you and we at the same level, not better, not worse, but in different stages.

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

    The channel deserves to have minimum 2 million sub

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

    Thank you for this clear lesson.

  • @steevbravo
    @steevbravo 5 років тому

    Simple explanation. Keep up the good work!

  • @saldownik
    @saldownik 4 роки тому

    Great vid, very informative. Thanks.

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

    thank you so much body, you saved me from lot of errors !

  • @foREVer1996123
    @foREVer1996123 5 років тому

    Thanks! the explanation is so clear.

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

    love this guy way of explaining

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

    We need a babel vid from you Kyle!

  • @KhaPiano
    @KhaPiano 4 роки тому

    Very simple and clear video. Thanks!

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

    Thanks man! This helped me a lot...

  • @TheUltimateTrainJourney
    @TheUltimateTrainJourney 4 роки тому

    Simply great and justified as channel name

  • @1apocalyps
    @1apocalyps 4 роки тому

    Straight, to the point, no fluffs = (Attention + Learning) >= (Knowledge + Success) = $$$

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

    Thank you so much for these

  • @eddiejaoude
    @eddiejaoude 5 років тому

    Great explanation and demo 👍. Keep them coming 🤓

    • @WebDevSimplified
      @WebDevSimplified  5 років тому +1

      Thanks! I'm not planning to stop anytime soon.

    • @eddiejaoude
      @eddiejaoude 5 років тому

      Web Dev Simplified looking forward to the next one 🤓

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

    Thanks man. This was helpful.

  • @johnnicol4420
    @johnnicol4420 4 роки тому +15

    You have to make a Udemy "MODERN JAVASCRIPT COURSE" - Your way of explaining concepts are simple and easy to understand. You are a very good teacher. Looking forward to buying your new Udemy course. ;) Thanks for the help!

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

    Great tutorial. Thank you 💙

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

    Great Explanation! Just a little question. while importing other function which are not exported by default are we destructuring objects? as we know everything in JavaScript exists as an Object. so does this mean these files are also imported as Objects?

  • @cristianannese6040
    @cristianannese6040 4 роки тому +1

    amazing! thank you so much!!!

  • @samuelnmeje
    @samuelnmeje 4 роки тому

    nice explanation as user, you are awesome !!

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

    You never disappoint me kyle

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

    Crystal clear! Thanks 💪

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

    Excellent, succinct video on ES6 Modules. Thanks, Kyle
    {2021-06-14}, {2022-03-07}

  • @codypayne3711
    @codypayne3711 4 роки тому

    Just curious -- is the keystroke audio from your actual keyboard? If so, what keyboard do you use? Sounds oddly satisfying.
    Also, great explanation, thanks! I just started on modules on Codecademy and they didn't even really explain the basis -- that they're for splitting code into separate files to make them more easily maintained and easier to understand (as well as some accessibility functionality, which you introduced).

    • @WebDevSimplified
      @WebDevSimplified  4 роки тому

      That sound is from my keyboard. I have a Razer Deathstalker keyboard. It is essentially the cheapest Razer keyboard you could buy at the time. It was like $30 I think.

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

    Amazing video, thanks a lot

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

    its clearing my mind abou t ReactJS