Eric Elliott
Sep 6, 2018 · 1 min read

Composition isn’t about allowing people to break random chunks off a monolith. It’s about avoiding monolithic classes in the first place; instead favoring smaller, self-contained chunks of reusable code (e.g., pure or parameterized functions).

What I find is that I tend to favor code reuse by modular function imports, and reserve object composition to manipulate data structures as opposed to behaviors.

Eric Elliott

Written by

Make some magic. #JavaScript