# chuanxshi/javascript-patterns

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/chuanxshi-javascript-patterns).**

9,356 stars · 1,651 forks · HTML

## Links

- GitHub: https://github.com/chuanxshi/javascript-patterns
- Homepage: http://shichuan.github.io/javascript-patterns
- awesome-repositories: https://awesome-repositories.com/repository/chuanxshi-javascript-patterns.md

## Description

This is a reference collection of reusable JavaScript code examples that demonstrate classic software design patterns. The project provides practical implementations of creational patterns like Singleton and Factory, structural patterns such as Adapter and Decorator, and behavioral patterns including Observer, Strategy, and Command.

The documentation is organized around runnable code examples that show each pattern's structure and usage, serving as a practical guide for applying these solutions to recurring software architecture problems. The collection covers the three main categories of design patterns, offering concrete JavaScript implementations for each.

## Tags

### Education & Learning Resources

- [Design Pattern](https://awesome-repositories.com/f/education-learning-resources/educational-resources/reference-and-media/books-docs-reference/code-examples/design-pattern.md) — Provides runnable JavaScript code examples for classic software design patterns.
- [Design Pattern Examples](https://awesome-repositories.com/f/education-learning-resources/educational-resources/reference-and-media/books-docs-reference/code-examples/design-pattern-examples.md) — Provides JavaScript code snippets demonstrating practical implementations of software design patterns.

### Software Engineering & Architecture

- [JavaScript Implementations](https://awesome-repositories.com/f/software-engineering-architecture/architectural-design-patterns/design-patterns/javascript-implementations.md) — Provides JavaScript-specific implementations of classic software design patterns.
- [JavaScript Examples](https://awesome-repositories.com/f/software-engineering-architecture/behavioral-design-patterns/javascript-examples.md) — Provides JavaScript code examples for behavioral design patterns such as Observer, Strategy, and Command.
- [JavaScript Examples](https://awesome-repositories.com/f/software-engineering-architecture/creational-design-patterns/javascript-examples.md) — Provides JavaScript code examples for creational design patterns such as Singleton, Factory, and Builder.
- [JavaScript Implementations](https://awesome-repositories.com/f/software-engineering-architecture/design-pattern-collections/javascript-implementations.md) — Provides a curated collection of reusable JavaScript code examples for classic design patterns.
- [Design Pattern Implementations](https://awesome-repositories.com/f/software-engineering-architecture/design-pattern-implementations.md) — Ships reusable JavaScript code examples demonstrating structural and behavioral design pattern implementations. ([source](https://cdn.jsdelivr.net/gh/chuanxshi/javascript-patterns@master/README.md))
- [JavaScript Examples](https://awesome-repositories.com/f/software-engineering-architecture/structural-design-patterns/javascript-examples.md) — Provides JavaScript code examples for structural design patterns such as Adapter and Decorator.
