It's time to ditch Medium for good! 🌈⚡️

Introducing Devblog by Hashnode. Blog on your domain for FREE. Highly customizable and optimized for developers.

Learn more

I am Sean Larkin. Ask me anything.


Hi Sean, Thanks for doing this AMA.

Why webpack? How would you explain webpack to a beginner JavaScripter?

We love using and writing JavaScript modules right? The NodeJs ecosystem even came a long with CommonJS to adopt as the canonical module standard. Now we even have ECMAScript Module (Harmony Module Spec.). But sadly none of these work in the browser completely.

The main and original premesis was two things:

  • Let's you write modules, that get bundled into browser runnable code (as a build step).
  • Let's you split your code into multiple [a]sync bundles at build time to prevent overhead.

In a beginner JavaScripter's world, they probably don't know about:

  • Modules,
  • npm, history of its purpose
  • How we used to build code
  • Why it matters (perf, user experience).

So typically I'd try and shy away from teaching a beginner JavaScripter about webpack at first until they understand a bit more about the language and the importance of shipping minimal code to the browser.

Reply to this…

(37 questions) Take me to the AMA