GithubHelp home page GithubHelp logo

sowodev / design-patterns Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 2.1 MB

This repository is the implementation of Design Patterns in TypeScript.

License: MIT License

TypeScript 41.06% C++ 58.94%
design-patterns gang-of-four-design-patterns typescript

design-patterns's Introduction

Design Patterns Implementation through Problem Solving

Welcome to this Design Patterns Implementation repository! This repository serves as a comprehensive guide to understanding and implementing various design patterns using real-world problem-solving scenarios. The intention of this repository is for personal study and understand of the various design patterns implementations.

What are Design Patterns?

Design patterns are proven solutions to recurring design problems in software development. They provide reusable and elegant solutions that help improve code organization, maintainability, and extensibility. By studying and implementing design patterns, developers can learn to write more efficient, flexible, and maintainable code.

Repository Structure

The repository is organized into different directories, each representing a specific design pattern category. Each category contains individual directories for different design patterns. Inside each design pattern directory, you will find:

  1. Problem Statement: A brief explanation of the problem or scenario that the design pattern aims to address.
  2. Solution: A detailed implementation of the design pattern in code, along with explanations and comments.
  3. Benefits: Discussion on the advantages and use cases of the design pattern.
  4. Drawbacks: Any potential downsides or limitations of the design pattern.
  5. Examples: Additional code examples showcasing variations and real-world applications of the design pattern.

Design Pattern Categories

This repository covers a wide range of design patterns categorized as follows:

  1. Creational Patterns: Focus on object creation mechanisms, trying to create objects in a manner suitable to the situation.
  2. Structural Patterns: Deal with object composition, creating relationships between objects to form larger structures.
  3. Behavioral Patterns: Address how objects interact and communicate with each other.

How to Use This Repository

  1. Clone the repository to your local machine using the following command:
git clone https://github.com/sowodev/design-patterns.git
  1. Navigate to the specific design pattern directory you're interested in.
  2. Read through the problem statement to understand the context of the design pattern.
  3. Study the provided solution, benefits, drawbacks, and examples.
  4. Experiment with the code examples to gain a deeper understanding.
  5. Feel free to adapt and incorporate these design patterns into your own projects as needed.

Acknowledgments

Many design patterns leaves margin to opionated implemantation, so it might have differences from each others implementations, but they main concepts continue to be important to the pattern implementation. Also the implementation may vary depending on the programming language used to implement the pattern, for a deep understanding of each DP, I recommend visiting the Refactoring Guru website, from which most of the references of this repository comes from. Please be aware that each implementation may not be the best possible implementation, the intent is to just show case the patterns.

License

This repository is licensed under the MIT License, allowing you to freely use, modify, and distribute the code.

Happy coding and exploring the world of design patterns!

Wendell Oliveira da Silva

design-patterns's People

Stargazers

 avatar

Watchers

 avatar

design-patterns's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.