The Importance Of Abstraction in JS
Netanel Basal
1.7K7

Although I like the idea of useful abstractions, the examples are not that well thought out.

  1. In a production system, how likely would you switch a library such as lodash? It is more likely you introduced a layer of maintenance there!
  2. Abstractions for API changes are cute, but when API changes it is more likely to break completely (not just the additional parameter)
  3. Often abstractions abstract too much. Eg it is notclear whether a value comes from a local cache or the network. This may result in terrible application performance

As always, there is no free lunch in software engineering. So before adapting any abstraction, think under which circumstances it will save you time and performance later!