Split up your code into smaller, reusable pieces Overview# ES2015 introduced built-in JavaScript modules. A module is a file containing JavaScript code and makes it easy to expose and hide certain values. The module pattern is a great way to split a larger file into multiple smaller, reusable pieces. It also promotes code encapsulation, since the values within modules are kept private inside the m
![Module Pattern | JavaScript Patterns](https://cdn-ak-scissors.b.st-hatena.com/image/square/c0ed230c263319c7d616450ce939aa43b342eec5/height=288;version=1;width=512/https%3A%2F%2Fjavascriptpatterns.vercel.app%2Fogimage1.png)