This project, WaffleShop, is a simple web application built with React and Typescript. Its main purpose is to demonstrate the usage of the decorator pattern in object-oriented programming.
The primary goal of WaffleShop is to provide a practical example of implementing the decorator pattern in a real-world scenario. By creating a virtual waffle shop where customers can customize their waffles with various toppings, sauces, and chocolates, we can showcase how the decorator pattern can be used to add additional behavior or features to objects dynamically.
- React: A popular JavaScript library for building user interfaces.
- Typescript: A statically typed superset of JavaScript that compiles to plain JavaScript.
- Decorator Pattern: A design pattern that allows behavior to be added to individual objects, either statically or dynamically, without affecting the behavior of other objects from the same class.
- Tailwind CSS: A utility-first CSS framework for quickly building custom designs.
To run the WaffleShop project locally, follow these steps:
- Clone this repository to your local machine.
- Navigate to the project directory.
- Install dependencies by running
npm install
. - Start the development server with
npm start
. - Open your browser and go to
http://localhost:3000
to view the application.