Skip to content

klajdm/ecommerce-skinet

Skinet E-Commerce Application

A full-stack e-commerce application built with Angular and ASP.NET Core, featuring a modern, responsive design and comprehensive e-commerce functionality.

πŸš€ Features

  • Product Catalog: Browse products with filtering, sorting, and pagination
  • Shopping Cart: Add/remove items with persistent cart functionality using Redis
  • User Authentication: Registration and login with JWT tokens
  • Order Management: Complete order processing and order history
  • Payment Integration: Stripe payment processing
  • Responsive Design: Mobile-first design with Bootstrap
  • Admin Features: Product and order management
  • Real-time Updates: Modern SPA with Angular

πŸ› οΈ Technology Stack

Backend

  • ASP.NET Core 8.0 - Web API framework
  • Entity Framework Core - ORM for data access
  • SQLite - Database for development
  • Redis - Caching and session storage
  • AutoMapper - Object mapping
  • Stripe - Payment processing
  • JWT - Authentication and authorization
  • Swagger - API documentation

Frontend

  • Angular 16 - Frontend framework
  • TypeScript - Programming language
  • Bootstrap 5 - CSS framework
  • NgBootstrap - Angular Bootstrap components
  • Font Awesome - Icons
  • RxJS - Reactive programming

Architecture

  • Clean Architecture - Separation of concerns
  • Repository Pattern - Data access abstraction
  • Unit of Work Pattern - Transaction management
  • Dependency Injection - Loose coupling

πŸ“‹ Prerequisites

πŸš€ Getting Started

1. Clone the repository

git clone https://github.com/klajdm/skinet.git
cd skinet

2. Backend Setup

Navigate to the API directory:

cd API

Restore NuGet packages:

dotnet restore

Update the database:

dotnet ef database update

Run the API:

dotnet run

The API will be available at https://localhost:5001

3. Frontend Setup

Navigate to the client directory:

cd client

Install npm packages:

npm install

Start the Angular development server:

ng serve

The application will be available at https://localhost:4200

4. Redis Setup

Make sure Redis is running on your machine. The application expects Redis to be available at localhost:6379.

πŸ“ Project Structure

skinet/
β”œβ”€β”€ API/                    # ASP.NET Core Web API
β”‚   β”œβ”€β”€ Controllers/        # API controllers
β”‚   β”œβ”€β”€ Dtos/              # Data transfer objects
β”‚   β”œβ”€β”€ Extensions/        # Service extensions
β”‚   β”œβ”€β”€ Helpers/           # Utility classes
β”‚   └── Middleware/        # Custom middleware
β”œβ”€β”€ Core/                  # Domain layer
β”‚   β”œβ”€β”€ Entities/          # Domain entities
β”‚   β”œβ”€β”€ Interfaces/        # Repository interfaces
β”‚   └── Specifications/    # Query specifications
β”œβ”€β”€ Infrastructure/        # Data access layer
β”‚   β”œβ”€β”€ Data/             # EF Core repositories
β”‚   β”œβ”€β”€ Identity/         # Identity implementation
β”‚   └── Services/         # Business services
└── client/               # Angular frontend
    └── src/
        └── app/          # Angular components and services

πŸ”§ Configuration

Backend Configuration

Update appsettings.json in the API project:

{
  "ConnectionStrings": {
    "DefaultConnection": "Data source=skinet.db",
    "IdentityConnection": "Data source=identity.db",
    "Redis": "localhost"
  },
  "Token": {
    "Key": "your-super-secret-key-here",
    "Issuer": "https://localhost:5001"
  },
  "StripeSettings": {
    "PublishableKey": "your-stripe-publishable-key",
    "SecretKey": "your-stripe-secret-key"
  }
}

Frontend Configuration

Update environment files in client/src/environments/:

export const environment = {
  production: false,
  apiUrl: 'https://localhost:5001/api/',
  stripePublishableKey: 'your-stripe-publishable-key'
};

πŸ§ͺ Testing

Backend Tests

cd API
dotnet test

Frontend Tests

cd client
ng test

πŸ“¦ Docker Support

Build and run with Docker Compose:

docker-compose up --build

🀝 Contributing

Contributions are welcome! Please see our Contributing Guidelines for details.

πŸ”’ Security

Please see our Security Policy for reporting security vulnerabilities.

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ‘€ Author

Klajdi Murataj

πŸ™ Acknowledgments

  • Angular team for the excellent framework
  • Microsoft for ASP.NET Core
  • All the open-source contributors whose packages make this project possible

πŸ—ΊοΈ Roadmap

  • Mobile app development
  • Advanced analytics dashboard
  • Multi-vendor support
  • Internationalization
  • Enhanced search functionality
  • Wishlist feature
  • Product reviews and ratings

⭐ Star this repo if you find it helpful!

About

Skinet E-Commerce Application (.NET + Angular)

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors