Design Pattern and Recipes?

01 May 2018

Design patterns are used and/or referenced by software engineers just as recipes are used and/or referenced by chefs. Recipes and design patterns are both generally repeatable solutions to a commonly occurring problem. For a chef, these problems may include: “How do I make cheesecake?” or even “Which do I pour first? The milk or the cereal?”. Recipes can be reused to help prevent subtle or major problems that can affect the dish overall. Chefs generally reference these recipes and improve these recipes over time. These recipes can be used by other chefs to either create the same dish or a different dish. This concept also applies to software engineers. Software engineers can utilize design patterns to solve commonly occurring problems which include: class and object creation, structural behavior of these classes and objects, and the behavioral design. These design patterns have been around for awhile and may be outdated, but the methodologies still stand.

The React Javascript library is a great example of a library that uses basic design patterns which include: observer, state, mediator, iterator, abstract factory, and many more. Semantic UI acts as a design pattern because it provides an initial template which can be modified to whatever class you need to use it for. The project I am working on, which is Hale-Manoa references several design patterns that are from digits and even from the open-source community. Throughout this course, the popularity of React has allowed me to quickly find solutions to the problems I have encountered. These solutions often reference design patterns in which I then model to fix these problems. Design patterns are very useful in life as it not only applies to software engineering but can be used in everyday life.