Javascript Modules | Export Import Syntax for ES6 Modules

Published: 02 November 2020
on channel: Dave Gray
16,615
495

Web Dev Roadmap for Beginners (Free!): https://bit.ly/DaveGrayWebDevRoadmap

Learn Javascript Modules and the ES6 Module syntax to import and export modules in this Javascript tutorial. Javascript ES6 Modules help you organize your code into reusable JS files, functions, and classes.

▶ This video is part of the JavaScript Tutorials for Beginners Playlist found here:    • Javascript Tutorials for Beginners  

Subscribe ➜ https://bit.ly/3nGHmNn

✅ Quick Concepts outline:
JavaScript Modules
(0:00) Intro
(0:30) ES6 Module Basics
(0:42) JS Modules are only supported on servers
(1:30) Use the Live Server extension in VS Code
(2:04) The script tag with type="module"
(2:22) No defer needed
(3:15) Strict mode by default
(3:40) Create a Javascript Module
(4:55) Export default
(5:15) Export { firstItem, secondItem }
(5:45) Export inline
(6:35) Import the default export
(7:23) Import { firstItem, secondItem }
(8:04) Rename imports
(9:03) Import the full namespace
(11:58) JavaScript Class export and import example
(15:02) Current browser support for modules

📚 Further Reading:
MDN Web Docs:
Javascript Modules: https://developer.mozilla.org/en-US/d...

📺 Learn Web Dev at these sites:
https://www.freecodecamp.org
https://www.theodinproject.com

✅ Follow Me:
Twitter:   / yesdavidgray  
LinkedIn:   / davidagray  
Reddit:   / daveoneleven  

Was this tutorial about JavaScript ES6 Modules helpful? If so, please share. Let me know your thoughts in the comments.

#javascript #modules #export


Watch video Javascript Modules | Export Import Syntax for ES6 Modules online without registration, duration hours minute second in high quality. This video was added by user Dave Gray 02 November 2020, don't forget to share it with your friends and acquaintances, it has been viewed on our site 16,615 once and liked it 495 people.