Coding Shorts: What Surprised Me About ECMAScript Modules

preview_player
Показать описание
The Pluralsight Course:

While creating my Pluralsight course (Modules in JavaScript), I learned some new things about ECMAScript Modules. Take a look at some things that surprised me:

00:00 - Introduction
00:21 - Without Modules
02:48 - Using CommonJS
03:19 - Renaming to .mjs
06:10 - Integrating with CommonJS NPM Packages
08:06 - ESM import() function
10:09 - Wrapping Up

If you like this video, you might like other videos in my Instructional Videos:

You can hire me too! You can reach me at my new website:
Рекомендации по теме
Комментарии
Автор

Good stuff Shawn. I was just looking at starting an upgrade process of some of our javascript to use ECMAScript modules in a web project. Perfect timing!

I've been following your content for years. I'm glad I found you on YouTube! I'll have to restart my Pluralsight subscription to go watch your course now. 🙂

BrianHallmanac
Автор

Hi Shawn, no need to 'use strict' in modules, all modules are treated as strict by default

DannyHille
Автор

Really interesting! Thanks. Would you need a try-catch block for the asynchronous imports?

collinsk
Автор

ES6 modules works a bit different in browser than node at 6:00 onwards. See importmaps to use NPM modules in browser using bare imports.

FlippieCoetser