Design patterns. How do you select yours?

imthedeveloper

ImTheDeveloper

Posted on October 8, 2017

Design patterns. How do you select yours?

I’ve recently found myself spending time reading up on the various design patterns out there, primarily JavaScript based but they can be applied to any language. I found this great free book which provides a good overview of what is possible in JS but it got me thinking. With so many design patterns out there I’ve hit a number of questions such as:

  • How should I identify a pattern that best suits my situation, what questions should I be asking myself?
  • Should I start out with a pattern for my whole project?
  • Is not knowing all of the patterns a bad thing? I feel there is great risk in only knowing a set way of doing things.
  • Can I just pick one or two and get quite far through my projects without bad practice?
  • How should I document my pattern for others to easily understand the structure of my project and code?
  • Is following something better than nothing?

My worry would really be selecting the wrong pattern and trying to force my code and project to match. It would be great to see how other people tackle these decisions.

💖 💪 🙅 🚩
imthedeveloper
ImTheDeveloper

Posted on October 8, 2017

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related