Design Patterns: Elements of Reusable Object-Oriented Software by Gamma, Erich

This book characterizes the kind of thinking that moves you from the low-level ‘small’ view of a software developer to the high level long-term view of a software architect.While entry-level and junior developers may spent hours arguing fruitlessly over whether OOP is dead or alive, or whether functional programming is better or worse, most senior engineers and software architects are able to use many different paradigms. They understand that these patterns are deeper than the paradigm they are implemented in.They understand that the concepts and ideas underlying these design patterns cannot and will not ever die because they express evergreen solutions to dealing with evolving software systems.Javascript made the prototype pattern its object model. Generators (and coroutines) that make async/await possible are often implemented as combinations of Factories and Iterators. The Observer pattern underlies almost every single reactive UI framework and most microservice architectures. Decorators have become mainstays in most languages, inversion of control (IoC) is crucial for dependency injection patterns (Angular, etc.), and on and on… In short… These patterns are used absolutely everywhere, yes, even today.Basically, anyone who says these patterns are dead is either profoundly confused or unaware of how prevalent they are underneath everything they do.For those who say you don’t need to know the patterns themselves because they are implemented as language features in modern languages… I would say that coders are generally afraid to use what they don’t understand. Have you ever seen someone try to do reactive state management well who didn’t understand the Observer pattern? It’s not pretty. Moreover, there is no language that offers every single one of these patterns as first-class objects, and certainly no language that has them tailor-made for your use case and your business logic.Understanding the problems that these design patterns solve will help you design better software systems no matter what language or framework you use. Understanding how they work is crucial to using them well and not taking the pros and cons of these abstractions for granted.Yes, the examples are in C++ and quite old, and I wish they updated this book to implement these patterns in a newer language like Python, Typescript, Go, Carbon, Kotlin, or C#… but even this slight deficiency doesn’t justify taking a star away. Every other part of the book is complete gold. It should be updated, but even this version is well-worth the money.