If you are familiar with the different module definitions and loaders you may want to skip to the “Bundlers” section. If you just want to read the comparisons you can skip to the “Comparisons” section.
Please note that the comparisons done in this article are based on a very simple example. I’m working on another article in which I’ll compare bundling results for bundling a React app.
Below are the specs of the machine that I used to run the builds:
- MacBook Pro (Retina, 15-inch, Mid 2015)
- Processor: 2.2 GHz Intel Core i7
- Memory: 16 GB 1600 MHz DDR3
- Graphics: Intel Iris Pro 1536 MB
All the code examples for this article are available on Gitlab.
- Two prominent module definitions were developed as part of the community effort: CJS (CommonJS) and AMD (Asynchronous Module Definition).
- AMD was defined an asynchronous model intended for modules in the browser and RequireJS is the most popular implementation of AMD.
- A standard module system was finally introduced in 2015 as…