A novel, efficient approach to JavaScript loading
summary
Serves JavaScript by teaching the server the module graph so the client requests only what it needs when it needs it, cutting recursive waterfalls (example: 8 requests/4‑step → ~400 ms) down to a single concatenated response and negative loading deltas for incremental loads. Uses Closure Compiler for per‑module minification, implements callback loading to download in parallel and execute in order, rewrites globals into a synthetic namespace to avoid pollution (size cost ~3–4% gzips away), and ships an open source moduleserver that runs in production on Google+.
AI-written summary · about
chapters (15)
- 0:00JavaScript loading challenges
- 1:18Dependency trees inefficiencies
- 3:42RequireJS and bundles limits
- 4:25Server-side dependency resolution
- 6:09Negative loading for incremental requests
- 7:54Callback loading for parallel execution
- 11:23Rescoping global symbols
- 13:31Cross-iframe code sharing
- 14:13Independent incremental requests
- 15:38Server implementation and graph
- 17:00Closure Compiler module support
- 18:47Protocol flexibility for modules
- 19:51Open source module server
- 21:14Enhancements and community
- 23:20Q&A on Closure and caching
related talks
20mModules made awesome. Lessons learned from YUI loader on Node.js
29mDesigning very large JavaScript applications
46mIn this JavaScript tooling jungle, a return to simplicity is...
01h 10mThe future of JavaScript modules: JS module blocks and native bundling
36mUnbundling the JavaScript module bundler
35mBrowser Package Management
28mDecoding JavaScript: Loading Performance —
45mLoading Modules Everywhere!
