John-David Dalton - SeattleJS Conference 2017
summary
A new ES module loader for Node 4+ implements import/export support and live bindings, does on-the-fly fast transpilation with caching, and ships as a ~40KB zero-dependency package (v0.2). Demos show a Hello World load and a live-binding example where one module resets a value and another adds to it, proving bindings update across modules. Features include CJS compatibility flags, unambiguous JS detection or source pragmas, optional syntax extensions, and gzipped modules that shrink lodash from 4.5MB to ~90KB.
AI-written summary · about
chapters (20)
- 0:00Introduction
- 0:42Why native ES modules matter
- 2:51CommonJS under the hood
- 3:57ESM syntax and browser support
- 5:02Node’s .mjs extension debate
- 6:11ESM loader for Node 4+
- 7:17Live bindings and JSS support
- 8:46Unambiguous JavaScript grammar
- 9:49Gzipped module loading
- 11:40Syntax extensions for imports/exports
- 13:47Environment variables and require
- 15:38Compatibility and defaults
- 17:26Demo time and setup
- 19:12Hello world with ESM loader
- 21:04Live binding demo
- 22:31Implementation details
- 24:16Performance and package size
- 25:43Security and stability
- 27:31Hiding module internals
- 29:20Q&A and resources
related talks
32mThe Importance of import and export
19mModule Frontiers
48mTomorrow's ES modules today
32mPlease Wait... Loading: A Talk of Two Loaders
45mLoading Modules Everywhere!
26mNode Es Modules - Something Almost, but not Quite Entirely Unlike Commonjs
37mModules for JS.next
22mPlease wait... loading: a tale of two loaders
