This document provides an overview of our modern, full-featured e-commerce application built using .NET 8 for the backend and Angular for the frontend. It delivers a seamless shopping experience with real-time updates, responsive design, and secure payment integration. 💻📱
- ⚙️ Backend: ASP.NET Core 8
- 🌐 Frontend: Angular
- 🔄 Real-time Communication: SignalR
- 🎨 Styling: Tailwind CSS
- 💳 Payment Integration: Stripe API
- 🗂️ Caching & Data Storage: Redis
- 🛍️ Product Management: Browse, search, and filter products effortlessly.
- 🔄 Real-time Updates: Instant updates on orders and notifications via SignalR.
- 💳 Secure Payments: Stripe integration for seamless and secure transactions. Refunds and coupon codes included.
- 🔐 Authentication & Authorization: Secure user authentication and role-based access.
- 📊 Order Tracking: Admin dashboard for real-time order status and tracking updates.
- 🗂️ User Cart Management: Redis is used to store user cart data efficiently.
- ⚡ Request Caching: Redis caches frequent requests to improve performance and reduce server load.
To run this application locally, please follow the steps below:
Ensure you have the following installed:
- 🐳 Docker
- 🛠️ .NET SDK v8
- 📦 NodeJS (v20.11.1 or later) (Optional for Angular dev mode)
git clone https://github.com/BernieTv/.NET-Eccomerce-with-Angular
cd .NET-Eccomerce-with-Angular
# From the solution folder
dotnet restore
# Navigate to the Angular client folder
cd client
npm install
To enable payment functionality, set up your Stripe keys:
- Create an
appsettings.json
file in the API folder:
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
},
"StripeSettings": {
"PublishableKey": "pk_test_REPLACEME",
"SecretKey": "sk_test_REPLACEME",
"WhSecret": "whsec_REPLACEME"
},
"AllowedHosts": "*"
}
- Set up Stripe CLI for local webhook forwarding:
stripe login
stripe listen --forward-to https://localhost:5001/api/payments/webhook -e payment_intent.succeeded
The app requires SQL Server and Redis. Start these services using Docker:
docker compose up -d
Ensure no conflicting services are running on port 1433 (SQL Server) or port 6379 (Redis).
Run the backend API:
cd API
dotnet run
Access the app locally: 🌍 https://localhost:5001
To enable development mode with SSL:
cd client/ssl
mkcert localhost
Start Angular Dev Server:
cd client
ng serve
Browse to: 🌐 https://localhost:4200
Use Stripe test cards available here for payment simulation.
This project is licensed under the MIT License. 📝