Skip to content

Juudini/ecommerce-web-api

Repository files navigation

Typing SVG

This project is a Ecommerce application that demonstrates the use of Clean Architecture, Domain-Driven Design (DDD), and Clean Code principles. The application is designed to showcase best practices for building maintainable and scalable software.


Ing Progress

🧩 Languages & Tools

Features

  • Domain-Driven Design (DDD): The project follows DDD principles by organizing the codebase into clear and well-defined domains, such as "Order," "Customer," and "Menu." Each domain has its own folder structure with distinct responsibilities.

  • Clean Architecture: Clean Architecture is implemented to ensure separation of concerns and maintainability. The codebase is divided into layers, including "Application," "Domain," and "Infrastructure," each with a specific role.

  • Clean Code: Clean Code principles are applied throughout the project to enhance code readability, maintainability, and testability. Descriptive variable and function names, SOLID principles, and best practices are followed.

  • Modularity: The code is organized using barrel files, making it easy to navigate and understand the project structure. This modularity enhances code accessibility and maintainability.

Project Structure

  • /src
    • /domain: The heart of the application, housing the domain model, entities, and core business logic.
    • /infrastructure: Manages infrastructure-related tasks like database access and external service interactions.
    • /presentation: Handles user interfaces and API endpoints for interacting with the application.

Installation and Configuration

Follow the steps below to set up and run the application in your local environment:

  1. Clone this repository to your local machine:
git clone https://github.com/Juudini/ecommerce-web-api.git
  1. Navigate to the project directory:
cd ecommerce-web-api
  1. Install project dependencies:
npm i
  1. Migrate to initial schema to the database:
npx prisma db push
  1. Launch server:
npm run dev

Make sure you have the .env file in the root folder.

To access the documentation, open your web browser and enter the following URL:

http://localhost:4000/api/docs

This will take you to the API documentation, where you can explore the endpoints and learn how to interact with the application.

🔗 Links

LinkedIn Portfolio Email